removed trailing witespaces

This commit is contained in:
Ilya Puchka
2017-12-27 18:48:37 +01:00
parent 4bfdb73175
commit 662849e968
12 changed files with 51 additions and 51 deletions

View File

@@ -16,7 +16,7 @@ class BlockContext {
self.blocks[blockName] = [block]
}
}
func popBlock(named blockName: String) -> BlockNode? {
if var blocks = blocks[blockName] {
let block = blocks.removeFirst()
@@ -86,7 +86,7 @@ class ExtendsNode : NodeType {
}
let baseTemplate = try context.environment.loadTemplate(name: templateName)
let blockContext: BlockContext
if let _blockContext = context[BlockContext.contextKey] as? BlockContext {
blockContext = _blockContext
@@ -148,7 +148,7 @@ class BlockNode : NodeType {
// child node is a block node from child template that extends this node (has the same name)
var newContext: [String: Any] = [BlockContext.contextKey: blockContext]
if let blockSuperNode = child.nodes.first(where: {
if case .variable(let variable, _)? = $0.token, variable == "block.super" { return true }
else { return false}
@@ -170,7 +170,7 @@ class BlockNode : NodeType {
}
}
}
// render extension node
do {
return try context.push(dictionary: newContext) {