Factor out saving a PIL Image to django storage.

Review Request #3903 — Created Feb. 21, 2013 and submitted

Information

Djblets
master

Reviewers

Factor out saving a PIL Image to django storage.

Both the thumbnail and crop template tags do the same thing for taking a PIL
Image and saving it to a (potentially remote) storage. In addition, I need this
functionality in $SECRET_PROJECT, so I've factored it out into its own method.
Used this in $SECRET_PROJECT.
reviewbot
  1. This is a review from Review Bot.
      Tool: PEP8 Style Checker
      Processed Files:
        djblets/util/templatetags/djblets_images.py
      Ignored Files:
    
    
  2. 
      
chipx86
  1. 
      
  2. djblets/util/templatetags/djblets_images.py (Diff revision 1)
     
     
     
     
     
     
     
     
     
    Everything looks fine, but I'm curious, while you're in here... Any way we can chain the two together so we don't need the temp file?
    1. I had initially tried to make this work with StringIO but it seems to need a real file object.
  3. 
      
david
Review request changed
Status:
Completed
Change Summary:
Pushed to master (db4d760).