You are here

function should_render in Official Facebook Pixel 7

Check if pixel code should be rendered

Return value

boolean True is should render pixel code, otherwise false.

1 call to should_render()
official_facebook_pixel_page_build in ./official_facebook_pixel.module
Implements hook_page_build().

File

./official_facebook_pixel.module, line 78
Contains facebook_pixel.module.

Code

function should_render() {
  global $user;
  $roles = $user->roles;
  return !(is_array($roles) && in_array("administrator", $roles));
}