fix fatal exception
Merge pull request #1040 from Catrobat/fixFatalException

fix fatal exception