URL.import is not de-duplicating URLs that are already in the database. This appears to be due to find_or_create_by() not performing the find() query if one of the attributes is an empty Array. The other reason is that SQL UNIQUE INDEXs are not enforced on columns which allow NULL values.
URL.import
is not de-duplicating URLs that are already in the database. This appears to be due tofind_or_create_by()
not performing thefind()
query if one of the attributes is an empty Array. The other reason is that SQLUNIQUE INDEX
s are not enforced on columns which allowNULL
values.