NIFI-2405 corrected string equality checks

This closes #723.
This commit is contained in:
joewitt 2016-07-26 11:44:11 -04:00 committed by Pierre Villard
parent c3b4872b55
commit 15d1e1bbf8
1 changed files with 2 additions and 2 deletions

View File

@ -194,7 +194,7 @@ public class StandardSnippetDAO implements SnippetDAO {
final Snippet snippet = locateSnippet(snippetDTO.getId());
// if the group is changing move it
if (snippetDTO.getParentGroupId() != null && snippet.getParentGroupId() != snippetDTO.getParentGroupId()) {
if (snippetDTO.getParentGroupId() != null && !snippet.getParentGroupId().equals(snippetDTO.getParentGroupId())) {
// get the current process group
final ProcessGroup processGroup = flowController.getGroup(snippet.getParentGroupId());
if (processGroup == null) {
@ -217,7 +217,7 @@ public class StandardSnippetDAO implements SnippetDAO {
final StandardSnippet snippet = locateSnippet(snippetDTO.getId());
// if the group is changing move it
if (snippetDTO.getParentGroupId() != null && snippet.getParentGroupId() != snippetDTO.getParentGroupId()) {
if (snippetDTO.getParentGroupId() != null && !snippet.getParentGroupId().equals(snippetDTO.getParentGroupId())) {
final ProcessGroup currentProcessGroup = flowController.getGroup(snippet.getParentGroupId());
if (currentProcessGroup == null) {
throw new IllegalArgumentException("The current process group could not be found.");