Prevent traceback using refresh param

Make the same change as was made in f0d1043 to pacman.py
Fix typo introduced in f0d1043