services/sync/tps/extensions/mozmill/resource/stdlib/dom.js

Wed, 31 Dec 2014 07:53:36 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 07:53:36 +0100
branch
TOR_BUG_3246
changeset 5
4ab42b5ab56c
permissions
-rw-r--r--

Correct small whitespace inconsistency, lost while renaming variables.

michael@0 1 /* This Source Code Form is subject to the terms of the Mozilla Public
michael@0 2 * License, v. 2.0. If a copy of the MPL was not distributed with this
michael@0 3 * file, you can obtain one at http://mozilla.org/MPL/2.0/. */
michael@0 4
michael@0 5 var EXPORTED_SYMBOLS = ['getAttributes'];
michael@0 6
michael@0 7
michael@0 8 var getAttributes = function (node) {
michael@0 9 var attributes = {};
michael@0 10
michael@0 11 for (var i in node.attributes) {
michael@0 12 if (!isNaN(i)) {
michael@0 13 try {
michael@0 14 var attr = node.attributes[i];
michael@0 15 attributes[attr.name] = attr.value;
michael@0 16 }
michael@0 17 catch (e) {
michael@0 18 }
michael@0 19 }
michael@0 20 }
michael@0 21
michael@0 22 return attributes;
michael@0 23 }
michael@0 24

mercurial