Permalink
Browse files

Removing previously added braces and indentation. Looking at you @arian.

  • Loading branch information...
1 parent fd36e5f commit 399554fc83fd460b41a53063093b82d6c464788f @cpojer cpojer committed Apr 21, 2011
Showing with 4 additions and 7 deletions.
  1. +4 −7 Source/Element/Element.js
View
@@ -29,13 +29,10 @@ var Element = function(tag, props){
var attributes = parsed.attributes;
if (attributes) for (var i = 0, l = attributes.length; i < l; i++){
var attr = attributes[i];
@ibolmo

ibolmo Apr 21, 2011

Owner

i'd move the var attr into the for declaration or next to attributes declaration.

@cpojer

cpojer Apr 21, 2011

Owner

oh hello compiler.

- if (props[attr.key] == null){
- if (attr.value != null && attr.operator == '='){
- props[attr.key] = attr.value;
- } else if (!attr.value && !attr.operator){
- props[attr.key] = true;
- }
- }
+ if (props[attr.key] != null) continue;
+
+ if (attr.value != null && attr.operator == '=') props[attr.key] = attr.value;
+ else if (!attr.value && !attr.operator) props[attr.key] = true;
}
if (parsed.classList && props['class'] == null) props['class'] = parsed.classList.join(' ');

0 comments on commit 399554f

Please sign in to comment.