[TYPO3-core] RFC: #2278 - Hook request for t3lib_TCEmain::checkModifyAccessList()

Peter Niederlag peter at niederlag.de
Wed Nov 8 08:32:50 CET 2006


Hello,

Ernesto Baschny [cron IT] schrieb:
> Michael Stucki schrieb:
[...]
> The function returns "true if the user has general access to modify the
> $table". What is unclear if several extensions hook to this method. In
> the current suggestion, the "last hook" wins (be it true or false). I
> would rather have it return in a determinate way, for example:
> 
> - if all hooks PLUS default handling returns "TRUE" => return TRUE

that wouldn't enable what the original hook-author wanted to accomplish:
He wanted to *override* the denial of modification. How about *ignoring*
the default result and requiring *all  hooks* to return true? That would
need a different patch though.

> - else, return FALSE
> 
> This is also easier to document and don't cause unpredictable results.

You pointed to an important issue, it might be wise to do some more
proper thinking about this.

[...]
> As for the hooks name, I don't like the "_post" in this particular case,
> because we are not doing any "post" processing.

we post-process the state of the permission. But this is another naming
I feel comfortable with: hook-func=orig-func

[...]

Greets,
Peter
-- 
Peter Niederlag * Neuer Sandberg 9 * 31535 Neustadt *
Fon (privat): 05036 / 924 100 * Fon (Büro): 05036 / 924 101
Fon (mobil): 0172 / 516 48 55 * Fax 05036 / 924 105
callto:typo3support (skype)
http://www.niekom.de * TYPO3 und EDV Dienstleistungen *
http://www.clown-goli.de * Clown-Comedy-Jonglage-Animation *



More information about the TYPO3-team-core mailing list