diff --git a/js/ui/appIcon.js b/js/ui/appIcon.js index ab8ede104..b0a37b696 100644 --- a/js/ui/appIcon.js +++ b/js/ui/appIcon.js @@ -557,7 +557,8 @@ AppIconMenu.prototype = { this._source.app.launch(); this.emit('activate-window', null); } else if (child == this._toggleFavoriteMenuItem) { - let isFavorite = AppFavorites.getAppFavorites().isFavorite(this._source.app.get_id()); + let favs = AppFavorites.getAppFavorites(); + let isFavorite = favs.isFavorite(this._source.app.get_id()); if (isFavorite) favs.removeFavorite(this._source.app.get_id()); else