Hi!

Just tried your new version and it works like a charm, thanks for the fast fix!


Bye,

Andreas

Arttu Manninen schrieb:
Andreas Flack wrote:
Hi!

I just played around a little and it seems that the locking mechanism really is the culprit. If I just hit F5 in an edit form, two revisions are produced. When I disable the lock() function in metadata.php, this stops. When I save, another three revisions are produced (I don't know why it's sometimes five and sometimes six). When I disable the unlock() function, this returns to normal.

Ok, I found the problem. Every time the object is locked or unlocked, there is a call for `$object->metadata->set('locker, $user_guid);` which leads to multiple updates per request.

I fixed this by setting a key that will prevent some metadata keys from creating a new revision. Those keys are at the moment:

* locker
* locked
* approver
* approved

BTW: Approving an article produces two revisions as well, it would be good to disable RCS here as well.

I think that approvals shouldn't store a new revision at all. After all the nature of approvals is that some revision is really confirmed and don't see the need for creating a new revision because of that.

If my logic fails, please let me know and I'll remove it from the list of "No RCS".

MidCOM core probably should have a new release to fix this and some others related issues.



_______________________________________________
user mailing list
[email protected]
http://lists.midgard-project.org/mailman/listinfo/user

Reply via email to