Permalink
Browse files

Fixed autoclose behaviour

Fixed #36
  • Loading branch information...
1 parent 4c776b6 commit 53cc9ad8cd441ef87393e705e0ca0f6180e79c75 @syrusakbary committed Aug 28, 2012
Showing with 16 additions and 16 deletions.
  1. +4 −4 pyjade/compiler.py
  2. +4 −4 pyjade/ext/django/__init__.py
  3. +4 −4 pyjade/ext/jinja.py
  4. +4 −4 pyjade/ext/mako.py
View
@@ -244,10 +244,10 @@ def visitCode(self,code):
self.visit(code.block)
# if not code.buffer: self.buf.append('}')
- if not code.buffer:
- codeTag = code.val.strip().split(' ',1)[0]
- if codeTag in self.autocloseCode:
- self.buf.append('{%% end%s %%}'%codeTag)
+ if not code.buffer:
+ codeTag = code.val.strip().split(' ',1)[0]
+ if codeTag in self.autocloseCode:
+ self.buf.append('{%% end%s %%}'%codeTag)
def visitEach(self,each):
self.buf.append('{%% for %s in %s %%}'%(','.join(each.keys),each.obj))
@@ -57,10 +57,10 @@ def visitCode(self,code):
self.visit(code.block)
# if not code.buffer: self.buf.append('}')
- if not code.buffer:
- codeTag = code.val.strip().split(' ',1)[0]
- if codeTag in self.autocloseCode:
- self.buf.append('{%% end%s %%}'%codeTag)
+ if not code.buffer:
+ codeTag = code.val.strip().split(' ',1)[0]
+ if codeTag in self.autocloseCode:
+ self.buf.append('{%% end%s %%}'%codeTag)
def attributes(self,attrs):
return "{%% __pyjade_attrs %s %%}"%attrs
View
@@ -42,10 +42,10 @@ def visitCode(self,code):
self.visit(code.block)
# if not code.buffer: self.buf.append('}')
- if not code.buffer:
- codeTag = code.val.strip().split(' ',1)[0]
- if codeTag in self.autocloseCode:
- self.buf.append('{%% end%s %%}'%codeTag)
+ if not code.buffer:
+ codeTag = code.val.strip().split(' ',1)[0]
+ if codeTag in self.autocloseCode:
+ self.buf.append('{%% end%s %%}'%codeTag)
def visitEach(self,each):
self.buf.append('{%% for %s in %s %%}'%(','.join(each.keys),each.obj))
View
@@ -61,10 +61,10 @@ def visitCode(self,code):
self.visit(code.block)
# if not code.buffer: self.buf.append('}')
- if not code.buffer:
- codeTag = code.val.strip().split(' ',1)[0]
- if codeTag in self.autocloseCode:
- self.buf.append('</%%%s>'%codeTag)
+ if not code.buffer:
+ codeTag = code.val.strip().split(' ',1)[0]
+ if codeTag in self.autocloseCode:
+ self.buf.append('</%%%s>'%codeTag)
def visitEach(self,each):
self.buf.append('\\\n%% for %s in %s:\n'%(','.join(each.keys),each.obj))

0 comments on commit 53cc9ad

Please sign in to comment.