mirror of
https://github.com/vanitasvitae/Smack.git
synced 2024-11-25 21:42:07 +01:00
Minor refactoring in DataForm.hasHiddenFormTypeField()
This commit is contained in:
parent
55a967da93
commit
364fe12b38
1 changed files with 2 additions and 4 deletions
|
@ -213,14 +213,12 @@ public class DataForm implements PacketExtension {
|
||||||
* @return true if there is at least one field which is hidden.
|
* @return true if there is at least one field which is hidden.
|
||||||
*/
|
*/
|
||||||
public boolean hasHiddenFormTypeField() {
|
public boolean hasHiddenFormTypeField() {
|
||||||
boolean found = false;
|
|
||||||
for (FormField f : fields) {
|
for (FormField f : fields) {
|
||||||
if (f.getVariable().equals("FORM_TYPE") && f.getType() == FormField.Type.hidden) {
|
if (f.getVariable().equals("FORM_TYPE") && f.getType() == FormField.Type.hidden) {
|
||||||
found = true;
|
return true;
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return found;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
Loading…
Reference in a new issue