Removed two leftover print calls and changed how the singular news remove button functions. Previously the button was sending a GET request which then edited the database which should not be done. This has now been changed such that it send a POST request instead.
Why?
Improves code readability and functionality
How?
Added a javascript listener to the singular remove buttons that then sends the request and redirects back to the current page
Testing
Remember to add or update unit tests for new features and changes.
Description
What?
Removed two leftover print calls and changed how the singular news remove button functions. Previously the button was sending a GET request which then edited the database which should not be done. This has now been changed such that it send a POST request instead.
Why?
Improves code readability and functionality
How?
Added a javascript listener to the singular remove buttons that then sends the request and redirects back to the current page
Testing
Remember to add or update unit tests for new features and changes.
What type of test did you run?
Tried removing news in different kinds of situations (Just one news item, multiple, last news item, one from the middle etc.)
Did you test the changes in
Think of what is affected by these changes and could become broken
Translation
Programming style
Have you updated the README or other relevant documentation?
Is it Done?
Clean up your git commit history before submitting the pull request!