You are here

function workspace_content_type_load in Workspace 7

File

./workspace.module, line 116
Presents a user-centric view of content.

Code

function workspace_content_type_load($arg) {
  global $user;
  $found = FALSE;
  foreach (node_type_get_types() as $type => $object) {
    if ($type == $arg) {
      if (module_invoke_all('node_access', $type, 'create', $user)) {
        $found = TRUE;
      }
    }
  }
  return $found ? $arg : FALSE;
}