We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9755f8d commit 25755c5Copy full SHA for 25755c5
operator-framework/src/main/java/io/javaoperatorsdk/operator/ControllerUtils.java
@@ -84,10 +84,7 @@ private static Controller getAnnotation(ResourceController controller) {
84
return controller.getClass().getAnnotation(Controller.class);
85
}
86
87
- public static boolean hasDefaultFinalizer(CustomResource resource, String finalizer) {
88
- if (resource.getMetadata().getFinalizers() != null) {
89
- return resource.getMetadata().getFinalizers().contains(finalizer);
90
- }
91
- return false;
+ public static boolean hasGivenFinalizer(CustomResource resource, String finalizer) {
+ return resource.getMetadata().getFinalizers() != null && resource.getMetadata().getFinalizers().contains(finalizer);
92
93
0 commit comments