Error after switching code branches in browser