diff options
author | Petr Vobornik <pvoborni@redhat.com> | 2013-01-31 17:25:14 +0100 |
---|---|---|
committer | Petr Vobornik <pvoborni@redhat.com> | 2013-05-06 16:22:17 +0200 |
commit | 31d7486b88bc0e30c8a84ab4d2f73c35a700dad8 (patch) | |
tree | f28ee432487ef269e285064c5588e4b4168c5205 /install/ui/src/freeipa/ipa.js | |
parent | 7edf044a440d9a7f60c691811acedfc6a20ecbfe (diff) | |
download | freeipa-31d7486b88bc0e30c8a84ab4d2f73c35a700dad8.tar.gz freeipa-31d7486b88bc0e30c8a84ab4d2f73c35a700dad8.tar.xz freeipa-31d7486b88bc0e30c8a84ab4d2f73c35a700dad8.zip |
Remove IPA.nav usage, obsolete entity.get_primary_key
https://fedorahosted.org/freeipa/ticket/3236
Diffstat (limited to 'install/ui/src/freeipa/ipa.js')
-rw-r--r-- | install/ui/src/freeipa/ipa.js | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/install/ui/src/freeipa/ipa.js b/install/ui/src/freeipa/ipa.js index c1ed72214..7097aae8d 100644 --- a/install/ui/src/freeipa/ipa.js +++ b/install/ui/src/freeipa/ipa.js @@ -2058,9 +2058,16 @@ IPA.is_empty = function(value) { if (value instanceof Array) { empty = empty || value.length === 0 || (value.length === 1) && (value[0] === ''); - } - - if (value === '') empty = true; + } else if (typeof value === 'object') { + var has_p = false; + for (var p in value) { + if (value.hasOwnProperty(p)) { + has_p = true; + break; + } + } + empty = !has_p; + } else if (value === '') empty = true; return empty; }; |