feat: show !sheets found error via notify

This commit is contained in:
karishmas6
2024-10-24 06:20:28 +05:30
parent d20c77fa9c
commit 43bc1f926b

View File

@@ -28,7 +28,7 @@ export const IntegrationSettingsModal = ({ isOpen, handleStart, handleClose }: I
const [loading, setLoading] = useState(false);
const [error, setError] = useState<string | null>(null);
const { recordingId } = useGlobalInfoStore();
const { recordingId, notify } = useGlobalInfoStore();
const [recording, setRecording] = useState<any>(null);
const authenticateWithGoogle = () => {
@@ -52,6 +52,7 @@ export const IntegrationSettingsModal = ({ isOpen, handleStart, handleClose }: I
setSpreadsheets(response.data);
} catch (error: any) {
console.error('Error fetching spreadsheet files:', error.response?.data?.message || error.message);
notify('error', `Error fetching spreadsheet files: ${error.response?.data?.message || error.message}`);
}
};