Turns out that check was needed. Only call it if there is a shell
Actually fixes #100 and fixes #104 too