nit: } else if

or if you want to use this way, you should do the same here https://github.com/mozilla-b2g/gaia/pull/12708/files#diff-e2ee3c6b975b22e3d90a6be10c7b68ceR38