Fixed a couple of errors in favorite.js