Update url paths and add function behind login setting