mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 13:12:46 +00:00 
			
		
		
		
	AK+Everywhere: Use Optional for URLParser::parse's base_url parameter
This commit is contained in:
		
							parent
							
								
									38bdf4d159
								
							
						
					
					
						commit
						9915fa72fb
					
				
					 12 changed files with 31 additions and 32 deletions
				
			
		|  | @ -113,8 +113,7 @@ ErrorOr<Optional<AK::URL>> Response::location_url(Optional<String> const& reques | |||
|         return Optional<AK::URL> {}; | ||||
| 
 | ||||
|     // 3. If location is a header value, then set location to the result of parsing location with response’s URL.
 | ||||
|     auto base_url = *url(); | ||||
|     auto location = AK::URLParser::parse(location_values.first(), &base_url); | ||||
|     auto location = AK::URLParser::parse(location_values.first(), url()); | ||||
|     if (!location.is_valid()) | ||||
|         return Error::from_string_view("Invalid 'Location' header URL"sv); | ||||
| 
 | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 networkException
						networkException