Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[JENKINS-13742] Field validation does not pass required query parameters
when some fields are specified in a nested Describable # On branch master # Changes not staged for commit: # (use "git add <file>..." to update what will be committed) # (use "git checkout -- <file>..." to discard changes in working directory) * src/main/java/com/collabnet/ce/webservices/CTFProject.java (getOrCreateDocumentFolder, verifyPath): strip file separators from beginning and end of path * src/main/java/com/collabnet/ce/webservices/CollabNetApp.java (fromStapler): renamed overrideAuth to connectionFactory, the former is more descriptive, but the checkbox takes the name of the composite field. Added RelativeParameter annotations to the other arguments. Also the password field may contain the encrypted form, so using Secret to transform into plaintext. * src/main/java/hudson/plugins/collabnet/ConnectionFactory.java Add a fromStapler method so this can be used in validations that are internal to the composite field, such as the modified doCheckPassword method. * src/main/java/hudson/plugins/collabnet/auth/CNAuthProjectProperty.java (doFillProjectItems): simplified by using getProjectList method. * src/main/java/hudson/plugins/collabnet/browser/TeamForge.java (doFillProjectItems, doFillRepoItems): Added code to logoff the CTF session * src/main/java/hudson/plugins/collabnet/tracker/CNTracker.java (doFillTrackerItems): Add a null check to avoid NPE, if auth data is not found * src/main/java/hudson/plugins/collabnet/util/CNFormFieldValidator.java Several methods are modified to add null checks for the CollabNetAuth arg and to ensure the session is logged off. Prior to this change some methods did one and others did the other and some did neither. * src/main/java/hudson/plugins/collabnet/util/ComboBoxUpdater.java (getUsers): Add null check on CollabNetApp arg
- Loading branch information
Showing
8 changed files
with
110 additions
and
47 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters