diff --git a/smack-extensions/src/main/java/org/jivesoftware/smackx/xdatavalidation/provider/DataValidationProvider.java b/smack-extensions/src/main/java/org/jivesoftware/smackx/xdatavalidation/provider/DataValidationProvider.java index a495397fa..67b82447a 100644 --- a/smack-extensions/src/main/java/org/jivesoftware/smackx/xdatavalidation/provider/DataValidationProvider.java +++ b/smack-extensions/src/main/java/org/jivesoftware/smackx/xdatavalidation/provider/DataValidationProvider.java @@ -50,7 +50,8 @@ public class DataValidationProvider { int eventType = parser.next(); switch (eventType) { case XmlPullParser.START_TAG: - switch (parser.getName()) { + String name = parser.getName(); + switch (name) { case OpenValidateElement.METHOD: dataValidation = new OpenValidateElement(dataType); break;