@register_tag<EOL>def calculate_dimensions(image, long_side, short_side):
if image.width >= image.height:<EOL><INDENT>return '<STR_LIT>'.format(long_side, short_side)<EOL><DEDENT>return '<STR_LIT>'.format(short_side, long_side)<EOL>
Returns the thumbnail dimensions depending on the images format.