-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] #155
Labels
bug
Something isn't working
Comments
8 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Description
When a databsae conncetion is made, the connection is not closed after its use. Further, that close call must be made in a finally block otherwise an exception could keep the call from being made.
Expected behavior
A final clause after the try-catch to close the database connection
Actual behavior
No final clause to close the database conneciton
Possible fix
Add a final clause to close the connection
Steps to reproduce
Selecting a book which calls the getBookById() method call that then creates a database connection
Context
Exception was thrown when querying book.
Additional information
No response
The text was updated successfully, but these errors were encountered: