Check if user setting pair exists before inserting/updating it.

If it exists it's inserted else the date is updated.
This fixes a (harmless) error that clutters the postgres log.
Fixes #958