|  | @@ -41,13 +41,13 @@ function pleroma_set_background_image_from_url {
 | 
	
		
			
			| 41 | 41 |  
 | 
	
		
			
			| 42 | 42 |      ext=
 | 
	
		
			
			| 43 | 43 |      if [ ${#url} -gt 0 ]; then
 | 
	
		
			
			| 44 |  | -        if [[ $url == *".jpeg" || $url == *".jpg" ]]; then
 | 
	
		
			
			|  | 44 | +        if [[ "$url" == *".jpeg" || "$url" == *".jpg" ]]; then
 | 
	
		
			
			| 45 | 45 |              ext="jpg"
 | 
	
		
			
			| 46 | 46 |          fi
 | 
	
		
			
			| 47 |  | -        if [[ $url == *".png" ]]; then
 | 
	
		
			
			|  | 47 | +        if [[ "$url" == *".png" ]]; then
 | 
	
		
			
			| 48 | 48 |              ext="png"
 | 
	
		
			
			| 49 | 49 |          fi
 | 
	
		
			
			| 50 |  | -        if [[ $url == *".gif" ]]; then
 | 
	
		
			
			|  | 50 | +        if [[ "$url" == *".gif" ]]; then
 | 
	
		
			
			| 51 | 51 |              ext="gif"
 | 
	
		
			
			| 52 | 52 |          fi
 | 
	
		
			
			| 53 | 53 |      fi
 | 
	
	
		
			
			|  | @@ -62,7 +62,7 @@ function pleroma_set_background_image_from_url {
 | 
	
		
			
			| 62 | 62 |              fi
 | 
	
		
			
			| 63 | 63 |  
 | 
	
		
			
			| 64 | 64 |              # get the new image
 | 
	
		
			
			| 65 |  | -            wget $url -O bg_custom.${ext}
 | 
	
		
			
			|  | 65 | +            wget "$url" -O bg_custom.${ext}
 | 
	
		
			
			| 66 | 66 |              if [ ! -f bg_custom.${ext} ]; then
 | 
	
		
			
			| 67 | 67 |                  echo "$url"
 | 
	
		
			
			| 68 | 68 |                  echo $'Custom background image for pleroma could not be downloaded'
 |