diff options
author | Dries Buytaert <dries@buytaert.net> | 2009-06-02 07:02:17 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2009-06-02 07:02:17 +0000 |
commit | 0b1a243e53d8db877129ba0aabfeb36dea1a1935 (patch) | |
tree | e56855b5feb3480bc996d4515ca44394465c3bc7 /modules/field/field.module | |
parent | e474fbbd6c57ed6de2ef4b0e826a6ba3b75a11c9 (diff) | |
download | brdo-0b1a243e53d8db877129ba0aabfeb36dea1a1935.tar.gz brdo-0b1a243e53d8db877129ba0aabfeb36dea1a1935.tar.bz2 |
- Patch #439236 by alex_b: field_attach_create_bundle() undefined when creating a content type on hook_update().
Diffstat (limited to 'modules/field/field.module')
-rw-r--r-- | modules/field/field.module | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/modules/field/field.module b/modules/field/field.module index c86ac521f..b35d76b13 100644 --- a/modules/field/field.module +++ b/modules/field/field.module @@ -5,6 +5,14 @@ * Attach custom data fields to Drupal objects. */ +/* + * Load all Field API functions, either directly or via an + * autoloader. We can't do this during hook_init() because it isn't + * run during update.php. + */ +require(DRUPAL_ROOT . '/modules/field/field.crud.inc'); +require(DRUPAL_ROOT . '/modules/field/field.autoload.inc'); + /** * @defgroup field Field API * @{ @@ -108,14 +116,8 @@ function field_help($path, $arg) { /** * Implement hook_init(). - * - * TODO D7: Determine which functions need to always be "loaded", and - * put autoloaders for them into field.autoload.inc. Also figure out - * how to make this work during installation. */ function field_init() { - module_load_include('inc', 'field', 'field.crud'); - module_load_include('inc', 'field', 'field.autoload'); drupal_add_css(drupal_get_path('module', 'field') . '/theme/field.css'); } |