Too lax unique constraints for Thumbnail coped with "on demand" thumbnail
generation may leave database in inconsistent state where two thumbnail for
the same size are saved. We should be able to prevent that from happening
by generating all thumbnails when we save the image. Should fix#24, but
I can't figure out a way to actually test it.
This commit is a foundation upon a more robust image fetching code
will be built in the future, and it already fixes at least one weird
issue I've seen.
"origin" is an optional field that stores the URI for the site
that the image has been saved from, it's going to be used only from
bookmarklet. Fixes#63