You are here

function workbench_moderation_node_type_moderated in Workbench Moderation 7.3

Same name and namespace in other branches
  1. 7 workbench_moderation.module \workbench_moderation_node_type_moderated()

Determines if this content type is set to be moderated

Parameters

$type: String, content type name

Return value

boolean

14 calls to workbench_moderation_node_type_moderated()
WorkbenchModerationMigrateDestinationHandler::fields in ./workbench_moderation.migrate.inc
WorkbenchModerationModerateTabTestCase::testModerateTab in tests/workbench_moderation.test
WorkbenchModerationNodeAccessTestCase::testNodeAccessRecords in tests/workbench_moderation.node_access.test
Creates a node and tests the creation of node access rules.
WorkbenchModerationViewUnpublishedTestCase::testViewUnpublished in tests/workbench_moderation.perms.test
workbench_access_rules_condition_content_is_using_workbench_moderation in ./workbench_moderation.rules.inc
Condition: Check if the content is using workbench moderation.

... See full list

File

./workbench_moderation.module, line 1091
Content moderation for Workbench.

Code

function workbench_moderation_node_type_moderated($type) {

  // Is this content even in moderatation?
  $options = variable_get("node_options_{$type}", array());
  if (in_array('revision', $options) && in_array('moderation', $options)) {
    return TRUE;
  }
  return FALSE;
}