Adding auto-orienting code to paperclip