1
0
mirror of https://github.com/mitb-archive/filebot synced 2024-11-17 14:55:09 -05:00

{c{1/0} ?: 0}

This commit is contained in:
Reinhard Pointner 2013-02-06 03:00:44 +00:00
parent 1c8e1972b6
commit 75322276a9

View File

@ -5,7 +5,7 @@ import java.util.regex.Pattern
// simplified switch/case pattern matching
Object.metaClass.match = { Map cases -> def val = delegate; cases.findResult { switch(val) { case it.key: return it.value} } }
def x(c) { try { c.call() } catch (Throwable e) { null } }
def c(c) { try { c.call() } catch (Throwable e) { null } }
/**