83e35a232381cc74dbfac503c4ec73a5d6c177df
ReblogRecord (TraverseDirectory's .txt-export parser) and the --likes API path both default every content field to the literal "." when their source has no value for that field, then pass it straight into UpdatePost. A blog with two export folders in different field formats -- a duplicate "_2" folder, or an export whose field set changed over time -- sends one record with real Title/Tags/Slug and another with those fields "." because that format never had a line for them. Re-importing both on every run flipped the row back and forth forever: net content never changed, but DateModified moved on every pass since each write really did change a column relative to the other write, just not relative to the true value. Every content column in UpdatePost's SET list is now guarded the same way RootBlogName/RootURL already were -- a "." parameter leaves the existing value alone instead of overwriting it -- and the change-detection WHERE clause carries the same exception, so a "."-only difference no longer fires the UPDATE at all. Deliberately narrow: only the literal "." is the sentinel, so an explicit empty string from a real record still overwrites. Verified against a throwaway DB using the exact SQL text and parameter binding from UpdatePost, reproducing the an-angry-wolf/adore-blk scenario found in the live DB: re-importing conflicting "." records now writes zero rows and leaves DateModified untouched, while a genuine content change still fires and still moves it. Co-Authored-By: Claude Opus 5 <[email protected]>
Description
No description provided
136 MiB
Languages
C#
98.1%
PLpgSQL
1.9%