-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Prevent simultaneous editing of comments and issues #31053
Conversation
Thank you for the feature! It is good for end users. However there are some blocking problems in my mind at the moment:
|
@wxiaoguang thank you for review. do you have any suggestion? maybe a 'content hash' colum as @drsybren said? or any generic solution? |
TBH I haven't thought about the details carefully. Some brief ideas (just my opinion):
For the frontend mechanism: I would strongly suggest to make it independent of backend and totally transparent (do not calculate "version+1" in frontend). It could use an abstracted variable like |
I would agree since only content has the version, we should use a name like But I don't think it's necessary to put |
@wxiaoguang changed |
Overall it looks good to me. Thank you for the updates. Actually, I still think we should make the "comment" also support "content version" in one PR: they share the same code (especially the frontend code), and I do not think it's worth to add another migration for "comment" table. And one more thing, I think it's worth to write some test code to cover ChangeIssueContent's behavior. |
@lunny i think fail is not related to pr, right ? |
I think so. Let me restart the failed jobs. |
Looks like the CI failures are related. |
My bad. fixed migration. now looks like fixed |
(ps: no need to merge with every main commit manually, maintainers and the Gitea bot will do that 😄 ) |
* giteaofficial/main: (30 commits) Azure blob storage support (go-gitea#30995) Use repo as of renderctx's member rather than a repoPath on metas (go-gitea#29222) Ignore FindRecentlyPushedNewBranches err (go-gitea#31164) [skip ci] Updated translations via Crowdin Fix markup preview (go-gitea#31158) Swap word order in Comment and Close (go-gitea#31148) Fix push multiple branches error with tests (go-gitea#31151) Use vertical layout for multiple code expander buttons (go-gitea#31122) Remove duplicate `ProxyPreserveHost` in Apache httpd doc (go-gitea#31143) [skip ci] Updated translations via Crowdin Add an immutable tarball link to archive download headers for Nix (go-gitea#31139) Improve mobile review ui (go-gitea#31091) Add topics for repository API (go-gitea#31127) Add missed return after `ctx.ServerError` (go-gitea#31130) Fix API repository object format missed (go-gitea#31118) Fix DashboardRepoList margin (go-gitea#31121) Update JS dependencies (go-gitea#31120) [skip ci] Updated translations via Crowdin Prevent simultaneous editing of comments and issues (go-gitea#31053) Update demo site location from try.gitea.io -> demo.gitea.com (go-gitea#31054) ...
fixes #22907
Tested: