Code4GovTech / server

0 stars 4 forks source link

Update "Pull Request Event Handler" #63

Open Durgesh4993 opened 6 months ago

Durgesh4993 commented 6 months ago

It seems like you're trying to create an event handler for pull requests (PRs). If I understand correctly, you're filtering events based on their actions. there are a few points you might want to consider:

Error Handling: The code assumes that the input eventData is properly formatted and contains the expected keys. You might want to include error handling to ensure that the necessary keys are present and have the expected data types.

Return Values: In the handleEvent method, you currently have a return statement after filtering out certain events. This effectively ends the method execution. If you intend for the method to continue processing after filtering out certain events, you should remove the return statement.

Logging or Error Reporting: Instead of directly printing messages within the handleMerged and handleAbandoned methods, you might want to consider using a logging framework or some form of error reporting mechanism. This allows for better flexibility and control over how messages are handled.

beautify-picture

Durgesh4993 commented 6 months ago

@KDwevedi Can i work on this issue