On Fri, Feb 08, 2008 at 10:03:06AM +0000, Hans wrote: > I suspect something goes wrong there for you, and NotifyUpdate is > twice registered, and twice executed, resulting in double emails. > Why I do not know. But notify.php has no mechanism to prevent the > NotifyUpdate function from being twice registered for execution. > Maybe there is some sense in it, but maybe this should not happen.
This is probably the source of the difficulty -- NotifyUpdate really doesn't expect to be called more than once in a given session. But if multiple pages are being updated via UpdatePage(), then it would get reigstered multiple times and result in multiple postings. And if squelch is zero, or the squelch period has passed, then this could potentially generate multiple email messages for the same post. I think the fix would be to have PostNotify() store update information into an array, and have NotifyUpdate() process that array instead of checking and handling $IsPagePosted directly. Then we could fix it so that NotifyUpdate() is only registered once, at which point it does all processing as it's designed to do now. Pm _______________________________________________ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users