fixed appcrash when a field is empty
added json support