Last active
November 26, 2018 10:45
-
-
Save MwBakker/958cd48d6196301dd2abeaa4b5243adc to your computer and use it in GitHub Desktop.
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
public Boolean checkNewCat(String catName) | |
{ | |
this.hasCategory.observe(this.getApplication(), new Observer<Boolean>() { | |
@Override | |
public void onChanged(Boolean aBoolean) | |
{ | |
componentRepository.getComponentCategories().observe(this.getApplication(), new Observer<List<ComponentCat>>() { | |
@Override | |
public void onChanged(@Nullable final List<ComponentCat> componentCats) | |
{ | |
for (ComponentCat cat : componentCats) | |
{ | |
return !cat.getComponentCatName().equals(catName); | |
} | |
} | |
}); | |
} | |
}); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment