Index: chrome/browser/resources/options/chromeos/onc_data.js |
diff --git a/chrome/browser/resources/options/chromeos/onc_data.js b/chrome/browser/resources/options/chromeos/onc_data.js |
index 38a758c5dab00942daa0eb93cee5cd84cbc33160..0e8d8e8131d4ddc72f5dacf242fe097c1bb90092 100644 |
--- a/chrome/browser/resources/options/chromeos/onc_data.js |
+++ b/chrome/browser/resources/options/chromeos/onc_data.js |
@@ -140,6 +140,16 @@ cr.define('cr.onc', function() { |
}, |
/** |
+ * Returns true if the ONC property exists, false otherwise. |
+ * @param {string} key The property key. |
+ * @return {bool} Whether the property exists. |
+ */ |
+ hasValue: function(key) { |
+ var property = this.getManagedProperty(key); |
+ return property != undefined; |
+ }, |
+ |
+ /** |
* Returns the Source of this configuration. If undefined returns 'None'. |
* @return {string} The configuration source: 'None', 'User', 'Device', |
* 'UserPolicy', or 'DevicePolicy'. |