fixed to use new dev mode check