Просмотр исходного кода

Fix tags when loading a recipe without them

Tatiana Inama 6 лет назад
Родитель
Сommit
c00b22829e
1 измененных файлов с 3 добавлено и 1 удалено
  1. 3 1
      recipes/src/containers/Recipes/Create/index.tsx

+ 3 - 1
recipes/src/containers/Recipes/Create/index.tsx

@@ -46,7 +46,9 @@ class CreateRecipe extends React.Component<any, CreateRecipeState> {
               details: {
                 ...recipe.details,
                 url: this.state.scrapeUrl,
-              }
+              },
+              tags: recipe.tags || [],
+              course: recipe.course || [],
             }
           })
         })