Source

web2py-template / new_template.py

Diff from to

File new_template.py

 indentation = '    '
 unindentation_words_before = ('else', 'elif', 'except')
 unindentation_words_after = ('pass', 'break', 'continue', 'return')
+open_something = '([{'
+close_something = ')]}'
 
     
 def parse_string(text):
     if not line:
         return ''
     if line[0] == '=':
-        return 'response.write(%s)' % line[1:]
+        return 'response.write(%s)' % line[1:].strip()
     else:
         return line
 
     last_quote = ''
     last_character = ''
     line = []
-    open_something = '([{'
-    close_something = ')]}'
     opened = 0
 
     for character in python_code: