Skip to content

Commit

Permalink
fix: delete unused code
Browse files Browse the repository at this point in the history
  • Loading branch information
jsapro committed Jan 15, 2024
1 parent 834a017 commit 44aa48f
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 5 deletions.
1 change: 0 additions & 1 deletion src/hooks/use-form-and-validation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ export function useFormAndValidation(
switch (type) {
case 'text':
if (!value || value.trim() === '') {
console.log(value);
errors[type] = 'Это поле обязательно для заполнения';
} else if (value.trim().length < 2 || value.trim().length > 30) {
errors[type] = 'Имя должно быть не короче 2 символов и не длиннее 30 символов';
Expand Down
1 change: 0 additions & 1 deletion src/pages/profile/profile-addresses/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ export default function ProfileAddresses() {
}
return addressObj;
});
console.log(changedAddresses);
sendRequest(changedAddresses);
};

Expand Down
1 change: 0 additions & 1 deletion src/pages/profile/profile-user/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,6 @@ export default function ProfileUser() {
setUpdateMeSuccess('Данные успешно обновлены');
})
.catch((err) => {
console.log(err);
setUpdateMeError(err.errors[0].detail);
})
.finally(() => setDisabledButton(false));
Expand Down
2 changes: 0 additions & 2 deletions src/pages/recipe-list/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,10 @@ const RecipeList: React.FC = () => {
.recipesList()
.then((data) => {
setRecipeList(data);
console.log(recipeList);
})
.finally(() => {
setIsLoading(false);
});
// eslint-disable-next-line react-hooks/exhaustive-deps
}, []);

return (
Expand Down

0 comments on commit 44aa48f

Please sign in to comment.