added unique constraint for hashes

on upload checking error for unique constriant error
gifs cannot be resized
Merge pull request #2 from kir-dev/unique-hashes

Unique hashes