mirror of
https://github.com/miniflux/v2.git
synced 2025-06-27 16:36:00 +00:00
Refactor category validation
This commit is contained in:
parent
e45cc2d2aa
commit
4468ef1410
13 changed files with 122 additions and 212 deletions
|
@ -50,7 +50,7 @@ type FeedCreationArgs struct {
|
|||
func CreateFeed(store *storage.Storage, args *FeedCreationArgs) (*model.Feed, error) {
|
||||
defer timer.ExecutionTime(time.Now(), fmt.Sprintf("[CreateFeed] FeedURL=%s", args.FeedURL))
|
||||
|
||||
if !store.CategoryExists(args.UserID, args.CategoryID) {
|
||||
if !store.CategoryIDExists(args.UserID, args.CategoryID) {
|
||||
return nil, errors.NewLocalizedError(errCategoryNotFound)
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue