Skip to content

Version author gets overwritten with wrong uid #39672

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Closed
JammingBen opened this issue Jan 10, 2022 · 2 comments
Closed

Version author gets overwritten with wrong uid #39672

JammingBen opened this issue Jan 10, 2022 · 2 comments

Comments

@JammingBen
Copy link
Contributor

Steps to reproduce

  1. Set file_storage.save_version_author to true
  2. Create a file "test.txt" as admin user
  3. Share the file with "user01"
  4. As "user01", edit this file -> The current author is "user01", the author of the first version is "admin" -> all good!
  5. As "user01", roll back the first version -> current author is "admin" (good!), however, the author of the first version is now "admin" as well (bad!)

Expected behaviour

The version author should be "user01"

@JammingBen
Copy link
Contributor Author

JammingBen commented Jan 11, 2022

Another error which goes in a similar direction:

  • Set file_storage.save_version_author to false
  • Create a file "test.txt" as admin user
  • As "admin", create a new version of this file
  • As "admin", share the file with "user01"
  • Set file_storage.save_version_author to true
  • As "user01", create a new version of this file
  • As "user01", restore a previous version -> The current version will be moved to the version list, including "user01" as author -> good!
  • As "user01", roll back the version with "user01" as author again -> the current version (that has no author) will be moved to the version list -> "user01" is displayed as author for this version -> bad!

JammingBen added a commit that referenced this issue Jan 11, 2022
Fix issue with wrong version authors being saved
@JammingBen
Copy link
Contributor Author

Fixed via #39673

# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

No branches or pull requests

1 participant