Bugfix for `encode_with_override` psych extension

The `coder` passed to ActiveRecord::Base#encode_with does not necessarily have
a `tag=` method (it may just be a Hash). This causes issues with other callers,
eg https://github.com/Shopify/identity_cache/blob/master/lib/identity_cache/query_api.rb#L140

Conflicts:
	lib/delayed/psych_ext.rb
I think Rubocop got confused by the method definitions inside an `if`.
Make rubocop happier
Merge pull request #681 from godaddy/fix_encode_with_override

Bugfix for `encode_with_override` psych extension