Simplify substr
Use $this
Merge pull request #49 from lucasmichot/factorize-substr

Factorize substr