Skip to content
This repository has been archived by the owner on Jan 19, 2021. It is now read-only.

Commit

Permalink
slight fix on new photo path
Browse files Browse the repository at this point in the history
  • Loading branch information
Tim Watts committed Mar 14, 2012
1 parent 88984c2 commit 440b854
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/users/migrations/0010_userprofile_photo_migrate.py
Expand Up @@ -24,7 +24,7 @@ def ensure_dir(f):
for p in orm.UserProfile.objects.all():
try:
old_pic = '%s/%d.jpg' % (settings.USERPICS_PATH, p.id)
p.photo.save('%d.jpg' % p.id , File(file(old_pic)))
p.photo.save('userprofile/%d.jpg' % p.id , File(file(old_pic)))
p.photo.file = file(new_pic)
p.save()
print p.id
Expand Down

0 comments on commit 440b854

Please sign in to comment.