Fixed a couple of silly bugs in list.js

Added a missing import and handle unauthorized case correctly