(pkgName: string)
| 122 | |
| 123 | // Function to add/remove packages from favorites |
| 124 | public addFavorite(pkgName: string): string[] { |
| 125 | this.pullFavoriteNames(); |
| 126 | this.favoriteNames.add(pkgName); |
| 127 | this.pushFavoriteNames(); |
| 128 | return [...this.favoriteNames.values()]; |
| 129 | } |
| 130 | public removeFavorite(pkgName: string): string[] { |
| 131 | this.pullFavoriteNames(); |
| 132 | this.favoriteNames.delete(pkgName); |
no test coverage detected