Fix error passing blockId to the createEventHandler method which caused the initial creation of the Image Moderation function to fail in the case where a text moderation function already existed.
Also added code beautification to the initial publish of the event handler.
Followed guidelines
Please make sure to review and check all of these items before merging pull request
Followed SF GitHub guidelines for creating this branch.
Reviewed the code for any compile-time errors.
Resolved the linting issues for the code changed during development.
Tested this code on the Local.
Removed the console logs added during development(if any).
Description of change
Fix error passing blockId to the createEventHandler method which caused the initial creation of the Image Moderation function to fail in the case where a text moderation function already existed.
Also added code beautification to the initial publish of the event handler.
Followed guidelines
Please make sure to review and check all of these items before merging pull request