efficient checking of whether person logging on/off is an org member of same org as bot

Registered by Johannes Skartland

An efficient way of checking wether a person that logs on is a member of the bots org when it logs on?
(Not just MEMBER or higher security access, but actualy ORG member).

Currently using this in each module I need it in:

    /*
    This gets called if a buddy logs on/off
    */
    function buddy($name, $msg)
    { // Start function buddy()
      if ($msg == 1)
      {
         $this -> checkup = $this -> bot -> core("whois") -> lookup($name);
         if ($this -> checkup["org"] == $this -> bot -> guildname)
         {
            <whatyouwanttohappen>
            $this -> checkup = array();
         }
      }
   } // End function buddy()

with "$this -> checkup = array();" defined in the module,

Blueprint information

Status:
Not started
Approver:
None
Priority:
Undefined
Drafter:
None
Direction:
Needs approval
Assignee:
None
Definition:
New
Series goal:
None
Implementation:
Unknown
Milestone target:
None

Related branches

Sprints

Whiteboard

(?)

Work Items

This blueprint contains Public information 
Everyone can see this information.

Subscribers

No subscribers.