libraries.install 899 B

123456789101112131415161718192021222324252627282930313233343536
  1. <?php
  2. /**
  3. * @file
  4. * Install, uninstall, and update functions for libraries.module.
  5. */
  6. /**
  7. * Implements hook_schema().
  8. */
  9. function libraries_schema() {
  10. $schema['cache_libraries'] = drupal_get_schema_unprocessed('system', 'cache');
  11. $schema['cache_libraries']['description'] = 'Cache table to store library information.';
  12. return $schema;
  13. }
  14. /**
  15. * Create the 'cache_libraries' table.
  16. */
  17. function libraries_update_7200() {
  18. // Note that previous versions of this function created the table with a
  19. // different table comment.
  20. if (!db_table_exists('cache_libraries')) {
  21. $specs = libraries_schema();
  22. db_create_table('cache_libraries', $specs['cache_libraries']);
  23. }
  24. }
  25. /**
  26. * Rebuild the class registry.
  27. */
  28. function libraries_update_7201() {
  29. // The tests were split from a single libraries.test file into multiple files
  30. // during the 7.x-2.x cycle.
  31. registry_rebuild();
  32. }