Changed to try-statement
Merge pull request #97 from danielsoro/patch-1

Changed to try-statement