Convert new URL(String) to URI.create(String).toURL()

MSAL

Converts new URL(String) constructor to URI.create(String).toURL(). The URL constructor has been deprecated due to security vulnerabilities when handling malformed URLs. Using URI.create(String) provides stronger validation and safer URL handling in modern Java applications.

org.openrewrite.java.migrate.net.URLConstructorToURICreate
mod run . --recipe=org.openrewrite.java.migrate.net.URLConstructorToURICreate

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