Check for auto-redirect option before removing default store code

Fixes #2