finally
block SC-R1056The finally
clause is used in scenarios where you need to release any resources that you may have acquired such as file handles or database connections. If you haven't acquired any such resources and there is nothing to close or release, consider dropping the clause altogether.
try {
// Do something
} catch {
// Handle exceptions
} finally {
}
try {
// Do something
} catch {
// Handle exceptions
}