From aafb77c7ecec8a59e5ca6e11e874dd5867fe9c57 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miko=C5=82aj=20=22Natsuyasumi=22=20Kuranowski?= Date: Fri, 9 Dec 2016 15:08:16 +0100 Subject: [PATCH] Small fixes --- modules/ui/fields/address.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/ui/fields/address.js b/modules/ui/fields/address.js index 5fcb4aacb..b3a90c7e6 100644 --- a/modules/ui/fields/address.js +++ b/modules/ui/fields/address.js @@ -122,7 +122,7 @@ export function uiFieldAddress(field, context) { return a && a.countryCodes && _.includes(a.countryCodes, countryCode); }) || _.first(dataAddressFormats); - if (typeof addressFormat.widths != 'undefined') { widths = addressFormat.widths; } + if (typeof addressFormat.widths !== 'undefined') { widths = addressFormat.widths; } else { widths = {housenumber: 1/3, street: 2/3, city: 2/3, state: 1/4, postcode: 1/3}; } function row(r) { @@ -158,7 +158,7 @@ export function uiFieldAddress(field, context) { // Update // setup dropdowns for common address tags - if (typeof addressFormat.dropdowns != "undefined") { addrTags = addressFormat.dropdowns; } + if (typeof addressFormat.dropdowns !== 'undefined') { addrTags = addressFormat.dropdowns; } else { addrTags = [ 'street', 'city', 'state', 'province', 'district', 'subdistrict', 'suburb', 'place', 'postcode']; }