fix(templates): only change updatedAt for actual updates to workflow or metadata#2630
Merged
icecrasher321 merged 1 commit intostagingfrom Dec 29, 2025
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Contributor
Greptile SummaryRemoved Confidence Score: 5/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant Client
participant GET as GET /templates/[id]
participant PUT as PUT /templates/[id]
participant POST_Star as POST /templates/[id]/star
participant DELETE_Star as DELETE /templates/[id]/star
participant POST_Use as POST /templates/[id]/use
participant DB as Database
Note over Client,DB: Before: All operations updated updatedAt timestamp
Client->>GET: View template
GET->>DB: UPDATE views + 1
Note over DB: ❌ Previously: updatedAt = new Date()<br/>✅ Now: updatedAt unchanged
DB-->>GET: Success
GET-->>Client: Template data
Client->>POST_Star: Star template
POST_Star->>DB: UPDATE stars + 1
Note over DB: ❌ Previously: updatedAt = new Date()<br/>✅ Now: updatedAt unchanged
DB-->>POST_Star: Success
POST_Star-->>Client: Starred
Client->>DELETE_Star: Unstar template
DELETE_Star->>DB: UPDATE stars - 1
Note over DB: ❌ Previously: updatedAt = new Date()<br/>✅ Now: updatedAt unchanged
DB-->>DELETE_Star: Success
DELETE_Star-->>Client: Unstarred
Client->>POST_Use: Use template
POST_Use->>DB: UPDATE views + 1
Note over DB: ❌ Previously: updatedAt = now<br/>✅ Now: updatedAt unchanged
DB-->>POST_Use: Success
POST_Use-->>Client: Workflow created
Note over Client,DB: PUT endpoint still updates updatedAt for actual content changes
Client->>PUT: Update template metadata/workflow
PUT->>DB: UPDATE with updatedAt = new Date()
Note over DB: ✅ updatedAt still updated for real changes
DB-->>PUT: Success
PUT-->>Client: Updated template
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Only change updatedAt for templates for PUT call from deploy modal.
Type of Change
Testing
Tested manually.
Checklist