mirror of
				https://github.com/TeamPiped/Piped.git
				synced 2024-08-14 23:57:27 +00:00 
			
		
		
		
	Set range parameter like official client.
This commit is contained in:
		
							parent
							
								
									cd93328fb2
								
							
						
					
					
						commit
						5cbe60aaaf
					
				
					 1 changed files with 8 additions and 0 deletions
				
			
		| 
						 | 
					@ -122,6 +122,14 @@ export default {
 | 
				
			||||||
                            url.host = new URL(component.video.proxyUrl).host;
 | 
					                            url.host = new URL(component.video.proxyUrl).host;
 | 
				
			||||||
                            request.uris[0] = url.toString();
 | 
					                            request.uris[0] = url.toString();
 | 
				
			||||||
                        }
 | 
					                        }
 | 
				
			||||||
 | 
					                        if (url.pathname === "/videoplayback") {
 | 
				
			||||||
 | 
					                            const headers = request.headers;
 | 
				
			||||||
 | 
					                            if (headers.Range) {
 | 
				
			||||||
 | 
					                                url.searchParams.set("range", headers.Range.split("=")[1]);
 | 
				
			||||||
 | 
					                                request.headers = {};
 | 
				
			||||||
 | 
					                                request.uris[0] = url.toString();
 | 
				
			||||||
 | 
					                            }
 | 
				
			||||||
 | 
					                        }
 | 
				
			||||||
                    });
 | 
					                    });
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                    localPlayer.configure(
 | 
					                    localPlayer.configure(
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue