Improve comments

This commit is contained in:
Mark Kaylor 2023-05-05 10:07:33 +02:00
parent 71ae8a9396
commit b37993cea7
2 changed files with 4 additions and 3 deletions

View File

@ -232,7 +232,8 @@ const BulkActionsBar = ({
await onConfirmPublishAll(selectedEntries); await onConfirmPublishAll(selectedEntries);
clearSelectedEntries(); clearSelectedEntries();
} catch (err) { } catch (err) {
// the notification is handle in handleConfirmPublishAllData // The notification is handle in content-manager/pages/ListView/index.js
// bulkPublishMutation onError callback
} finally { } finally {
setIsConfirmButtonLoading(false); setIsConfirmButtonLoading(false);
togglePublishModal(); togglePublishModal();
@ -246,7 +247,8 @@ const BulkActionsBar = ({
await onConfirmUnpublishAll(selectedEntries); await onConfirmUnpublishAll(selectedEntries);
clearSelectedEntries(); clearSelectedEntries();
} catch (err) { } catch (err) {
// the notification is handle in handleConfirmUnpublishAllData // The error is handled in content-manager/pages/ListView/index.js
// bulkUnpublishMutation onError callback
} finally { } finally {
setIsConfirmButtonLoading(false); setIsConfirmButtonLoading(false);
toggleUnpublishModal(); toggleUnpublishModal();

View File

@ -103,7 +103,6 @@ function ListView({
const fetchClient = useFetchClient(); const fetchClient = useFetchClient();
const { post, del } = fetchClient; const { post, del } = fetchClient;
// Bulk publish mutation passing the fetchClient's url and data arguments
const bulkPublishMutation = useMutation( const bulkPublishMutation = useMutation(
(data) => (data) =>
post(`/content-manager/collection-types/${contentType.uid}/actions/bulkPublish`, data), post(`/content-manager/collection-types/${contentType.uid}/actions/bulkPublish`, data),