mirror of
				https://github.com/python-pillow/Pillow.git
				synced 2025-10-30 23:47:27 +03:00 
			
		
		
		
	Can't use objects in default args
This commit is contained in:
		
							parent
							
								
									51b46e00c2
								
							
						
					
					
						commit
						676d0c3b3b
					
				|  | @ -714,7 +714,7 @@ def _write_frame_data(fp, im_frame, offset, params): | |||
| # -------------------------------------------------------------------- | ||||
| # Legacy GIF utilities | ||||
| 
 | ||||
| def getheader(im, palette=None, info=[]): | ||||
| def getheader(im, palette=None, info=None): | ||||
|     """ | ||||
|     Legacy Method to get Gif data from image. | ||||
| 
 | ||||
|  | @ -728,6 +728,9 @@ def getheader(im, palette=None, info=[]): | |||
|     """ | ||||
|     used_palette_colors = _get_optimize(im, info) | ||||
| 
 | ||||
|     if info is None: | ||||
|         info = {} | ||||
| 
 | ||||
|     if not "background" in info and "background" in im.info: | ||||
|         info["background"] = im.info["background"] | ||||
| 
 | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	Block a user