You are here

function og_update_group in Organic groups 5

Same name and namespace in other branches
  1. 5.8 og.module \og_update_group()
  2. 5.2 og.module \og_update_group()
  3. 5.3 og.module \og_update_group()
  4. 5.7 og.module \og_update_group()
  5. 6.2 og.module \og_update_group()
  6. 6 og.module \og_update_group()
1 call to og_update_group()
og_nodeapi in ./og.module
Implementation of hook_nodeapi().

File

./og.module, line 1312

Code

function og_update_group($node) {
  $sql = "UPDATE {og} SET theme = '%s', selective = %d, register = %d, description = '%s', directory = %d, notification = %d, language = '%s', private = %d WHERE nid = %d";
  db_query($sql, $node->og_theme, $node->og_selective, $node->og_register, $node->og_description, $node->og_directory, $node->og_notification, $node->og_language, $node->og_private, $node->nid);
  if (!db_affected_rows()) {
    og_insert_group($node);
  }
}