Remove Object.finalize() invocations

MSAL

Remove calls to Object.finalize(). This method is called during garbage collection and calling it manually is misleading. Explicit finalize invocations can trigger resource cleanup prematurely while the object is still in use, leading to unpredictable behavior.

org.openrewrite.staticanalysis.RemoveCallsToObjectFinalize
mod run . --recipe=org.openrewrite.staticanalysis.RemoveCallsToObjectFinalize

Install it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.