Fixes crash (Issue #10)