I've been working with the most recent dev commits this evening, so this may be a non-issue by the morning as I notice you're still making commits -- but the same issue was present in the module a few hours ago before mm_content became mm_cck.
Basically the fid wasn't getting loaded or passed on in the harvest function in mm_cck.module around line 179. I changed:
$results = db_query('SELECT f.filepath, n.nid FROM {files} f
to
$results = db_query('SELECT f.filepath, n.nid, f.fid FROM {files} f
and added:
'fid' => $result['fid'],
to the files array (around line 193). On our install here, that results in the fid being correctly stored in media_mover_files as well as solving the duplication issue.
I've attached my patch here -- but be aware that it also includes a bunch of function renames left over from the old mm_content version as many of them in my most recent pull down were still not renamed.
thanks for all your work on this Arthur!
Brian / Open Media Project
| Comment | File | Size | Author |
|---|---|---|---|
| mm-cck-fixes.patch | 2.91 KB | civicpixel |
Comments
Comment #1
arthurf commentedHey Brian- thanks for the patch. You were right here- it need the fid so that it can check for uniqueness. I changed up the code slightly so it is cleaner, but you were right on. Thanks!