mirror of
				https://github.com/TeamPiped/Piped.git
				synced 2024-08-14 23:57:27 +00:00 
			
		
		
		
	Fix player destroying.
Regression from moving to a component.
This commit is contained in:
		
							parent
							
								
									2c8bde922c
								
							
						
					
					
						commit
						87e922e06d
					
				
					 2 changed files with 7 additions and 7 deletions
				
			
		| 
						 | 
				
			
			@ -136,6 +136,13 @@ export default {
 | 
			
		|||
                    ui.configure(config);
 | 
			
		||||
                });
 | 
			
		||||
        }
 | 
			
		||||
    },
 | 
			
		||||
    beforeUnmount() {
 | 
			
		||||
        if (this.player) {
 | 
			
		||||
            this.player.destroy();
 | 
			
		||||
            this.player = undefined;
 | 
			
		||||
            this.ui = undefined;
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
};
 | 
			
		||||
</script>
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -98,13 +98,6 @@ export default {
 | 
			
		|||
        this.getVideoData();
 | 
			
		||||
        this.getSponsors();
 | 
			
		||||
    },
 | 
			
		||||
    beforeUnmount() {
 | 
			
		||||
        if (window.player) {
 | 
			
		||||
            window.player.destroy();
 | 
			
		||||
            window.player = undefined;
 | 
			
		||||
            window.ui = undefined;
 | 
			
		||||
        }
 | 
			
		||||
    },
 | 
			
		||||
    watch: {
 | 
			
		||||
        "$route.query.v": function(v) {
 | 
			
		||||
            if (v) {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue