Skip to content

Commit 1be3cb7

Browse files
committed
1.4 - Fixed duplicated item in history when click on feed, I have to finish for related and for history
1 parent 126874d commit 1be3cb7

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

src/app/app.component.ts

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,10 +85,12 @@ export class AppComponent implements OnInit {
8585
}
8686

8787
getVideo(videoID: string, videoName: string) {
88-
this.currentVideoID = videoID;
89-
this.currentVideoName = videoName;
90-
this.player.loadVideoById(videoID);
91-
this.getRelatedVideos();
88+
if (videoID != this.currentVideoID) {
89+
this.currentVideoID = videoID;
90+
this.currentVideoName = videoName;
91+
this.player.loadVideoById(videoID);
92+
this.getRelatedVideos();
93+
}
9294
}
9395

9496
playerVars() {

0 commit comments

Comments
 (0)