Fix pre-commit script to properly handle multiple files and resolve ESLint warnings

This commit is contained in:
William Valentin
2025-09-07 13:34:39 -07:00
parent 8fa2d3fb60
commit 315303b120
33 changed files with 561 additions and 404 deletions

View File

@@ -97,7 +97,7 @@ const AuthPage: React.FC = () => {
if (!success) {
setError(`${provider} authentication failed. Please try again.`);
}
} catch (error) {
} catch {
setError(`${provider} authentication failed. Please try again.`);
}
};

View File

@@ -52,8 +52,10 @@ const ChangePasswordModal: React.FC<ChangePasswordModalProps> = ({
await authService.changePassword(user!._id, currentPassword, newPassword);
onSuccess();
onClose();
} catch (error: any) {
setError(error.message || 'Failed to change password');
} catch (error: unknown) {
setError(
error instanceof Error ? error.message : 'Failed to change password'
);
} finally {
setLoading(false);
}