Browse Source

refactor(ui): remove unnecessary finally block in SliderPage submission

Remove the finally block from the onboarding completion handler in
SliderPage to prevent redundant state updates when errors are already
handled within the catch block.
master
mortezaei 5 days ago
parent
commit
fc95309d5b
  1. 1
      src/components/Componentes/slider-page.tsx

1
src/components/Componentes/slider-page.tsx

@ -121,7 +121,6 @@ export default function SliderPage({ onClose }: SliderPageProps = {}) {
} catch (error) { } catch (error) {
console.error("Failed to complete onboarding:", error); console.error("Failed to complete onboarding:", error);
setSubmitError(t["Failed to update profile basic details. Please try again."] || "Failed to update profile basic details. Please try again."); setSubmitError(t["Failed to update profile basic details. Please try again."] || "Failed to update profile basic details. Please try again.");
} finally {
setIsSubmitting(false); setIsSubmitting(false);
} }
}; };

Loading…
Cancel
Save