You are here

function oembedcore_preset_delete in oEmbed 6.0

Remove a preset.

File

./oembedcore.module, line 437
Core functionality for oEmbed

Code

function oembedcore_preset_delete($preset) {
  db_query("DELETE FROM {oembedcore_preset} WHERE name = '%s' AND pid = %d", $preset->name, $preset->pid);

  // Clear the content.module cache (refreshes the list of formatters provided by oembedfield.module).

  //TODO: Extract this and move to oembedfield
  if (module_exists('content')) {
    content_clear_type_cache();
    drupal_rebuild_theme_registry();
  }
}