updated frontend code, removed test code