Replaced del with pop

This commit is contained in:
Andrew Murray 2016-06-18 11:25:39 +10:00
parent dc5c0d303c
commit 86828ffd2a
3 changed files with 3 additions and 6 deletions

View File

@ -1660,8 +1660,7 @@ class Image(object):
save_all = False save_all = False
if 'save_all' in params: if 'save_all' in params:
save_all = params['save_all'] save_all = params.pop('save_all')
del params['save_all']
self.encoderinfo = params self.encoderinfo = params
self.encoderconfig = () self.encoderconfig = ()

View File

@ -109,8 +109,7 @@ class ChunkStream(object):
cid = None cid = None
if self.queue: if self.queue:
cid, pos, length = self.queue[-1] cid, pos, length = self.queue.pop()
del self.queue[-1]
self.fp.seek(pos) self.fp.seek(pos)
else: else:
s = self.fp.read(8) s = self.fp.read(8)

View File

@ -5,8 +5,7 @@ import sys
import os import os
if "--installed" in sys.argv: if "--installed" in sys.argv:
sys_path_0 = sys.path[0] sys_path_0 = sys.path.pop(0)
del sys.path[0]
from PIL import Image, ImageDraw, ImageFilter, ImageMath from PIL import Image, ImageDraw, ImageFilter, ImageMath
from PIL import features from PIL import features