SurrealChat.net Services Development (Perl)/Channel access functions

Difference (from prior major revision) (no other diffs)

Changed: 1c1,19
LOL THERE ARE GHOST NIGGER CHILDREN IN MY PANTS

can_do



can_do($chan, $perm, $acc, $user)

Consider changing.

* %chan
** hash with two keys
*** AGENT - whether bot or $csnick
*** CHAN - well, the name of the channel.
* $perm is a string. passed into the db in the chanperm and chanlvl tables
* $acc is the rsult of get_best_acc(%chan, %user), if known. can be undef()
* %user is optional, but only if $acc is defined.
** is a hash containing NICK, ID, and AGENT.
** These must be accessed using get_user_nick, get_user_id, and get_user_agent. don't access the hash directly, as they may be undefined!

get_best_acc



get_best_acc($chan, $user)

Returns the best channel access level available to a user.

can_do

 can_do($chan, $perm, $acc, $user)

Consider changing.

get_best_acc

 get_best_acc($chan, $user)

Returns the best channel access level available to a user.


This page is read-only | View other revisions
Last edited January 6, 2005 1:40 pm (diff)
Search: