function _hosting_client_get_role

7.x-3.x hosting_client.module _hosting_client_get_role()

Shortcut to get the rid of the 'aegir client' role.

This hardcodes the 'aegir client' role name, so if it is changed, this will fail.

@todo the rid or role name should be a variable

Deprecated

remove this function once the above setting is implemented

1 call to _hosting_client_get_role()
hosting_client_register_user in client/hosting_client.module
Register a new user account for the client.

File

client/hosting_client.module, line 432
Allow clients to be created and granted permissions over sites, tasks etc.

Code

function _hosting_client_get_role() {
  return db_query("SELECT rid FROM {role} WHERE name = :name", array(':name' => 'aegir client'))->fetchField();
}