mirror of https://github.com/jenkinsci/jenkins.git
@CheckForNull
This commit is contained in:
parent
c7a236ca1b
commit
7076f0de7e
|
|
@ -2316,9 +2316,9 @@ public final class FilePath implements Serializable {
|
|||
/**
|
||||
* Shortcut for {@link #validateFileMask(String)} in case the left-hand side can be null.
|
||||
*/
|
||||
public static FormValidation validateFileMask(FilePath pathOrNull, String value) throws IOException {
|
||||
if(pathOrNull==null) return FormValidation.ok();
|
||||
return pathOrNull.validateFileMask(value);
|
||||
public static FormValidation validateFileMask(@CheckForNull FilePath path, String value) throws IOException {
|
||||
if(path==null) return FormValidation.ok();
|
||||
return path.validateFileMask(value);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -544,7 +544,7 @@ public abstract class AbstractProject<P extends AbstractProject<P,R>,R extends A
|
|||
* null if there's no available workspace.
|
||||
* @since 1.319
|
||||
*/
|
||||
public final FilePath getSomeWorkspace() {
|
||||
public final @CheckForNull FilePath getSomeWorkspace() {
|
||||
R b = getSomeBuildWithWorkspace();
|
||||
if (b!=null) return b.getWorkspace();
|
||||
for (WorkspaceBrowser browser : Jenkins.getInstance().getExtensionList(WorkspaceBrowser.class)) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue