Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,8 @@ To convert modules:

1. Place the unpacked Drupal 7 module in the `old` directory.
2. Visit `admin/config/development/coder-upgrade`, select the Directories tab,
and check the box next to the module you wish to convert. Click the Convert
files button.
3. The Drupal 7 code will be converted, then copied to the `new` directory.
and check the box next to the module you wish to convert.
3. Click the Convert Files button. The Drupal 7 code will be converted, then copied to the `new` directory.
4. In addition to the converted module in the `new` directory, a patch that converts the old module will be placed in the `patch` directory.

Details
Expand Down Expand Up @@ -88,15 +87,15 @@ There are no dependencies. Unlike the Drupal version, the Grammar Parser Library

Developers
----------
In the event of issues with the upgrade routines, debug output may be enabled on
the settings page of this module. This information is very verbose; it is recommended to enable this only with
In the event you encounter issues with the upgrade routines, debug output may be enabled on
the settings page of this module. This information is quite verbose; it is recommended to enable this only with
smaller files that include the code causing an issue.

Current Maintainers
-------------------

- [Docwilmot](https://github.com/docwilmot)
- [Robert J. Lang (bugfolder)]([bugfolder](http://github.com/bugfolder))
- [Robert J. Lang (bugfolder)](http://github.com/bugfolder)

Credits
-------
Expand Down
18 changes: 9 additions & 9 deletions conversions/end.inc
Original file line number Diff line number Diff line change
Expand Up @@ -144,9 +144,9 @@ function coder_upgrade_create_autoload($module_name, $module_path, $classes) {
'type' => T_DOC_COMMENT,
'value' => "/**\n * Implements hook_autoload_info().\n */",
);
$modulename = $module_name . '_autoload_info';
$function_name = $module_name . '_autoload_info';

$function = new PGPClass($modulename);
$function = new PGPClass($function_name);
$function->comment = $comment;
$function->type = T_FUNCTION;
$function->parameters = new PGPList();
Expand Down Expand Up @@ -319,9 +319,9 @@ function coder_upgrade_create_update_install($module_name, &$reader, &$nodes, $c
'type' => T_DOC_COMMENT,
'value' => "/**\n * Implements hook_install().\n */",
);
$modulename = $module_name . '_install';
$function_name = $module_name . '_install';

$function = new PGPClass($modulename);
$function = new PGPClass($function_name);
$function->comment = $comment;
$function->type = T_FUNCTION;
$function->parameters = new PGPList();
Expand Down Expand Up @@ -396,11 +396,11 @@ function coder_upgrade_create_update_1000($module_name, &$reader, &$nodes, $conf
// Set values for the new hook function.
$comment = array(
'type' => T_DOC_COMMENT,
'value' => "/**\n * Implements hook_update_N().\n */",
'value' => "/**\n * Migrate {$module_name} variables to config.\n */",
);
$modulename = $module_name . '_update_1000';
$function_name = $module_name . '_update_1000';

$function = new PGPClass($modulename);
$function = new PGPClass($function_name);
$function->comment = $comment;
$function->type = T_FUNCTION;
$function->parameters = new PGPList();
Expand Down Expand Up @@ -436,10 +436,10 @@ function coder_upgrade_create_update_last_removed($module_name, &$reader, &$node
'type' => T_DOC_COMMENT,
'value' => "/**\n * Implements hook_update_last_removed().\n */",
);
$modulename = $module_name . '_update_last_removed';
$function_name = $module_name . '_update_last_removed';

// Create the new hook function.
$function = new PGPClass($modulename);
$function = new PGPClass($function_name);
$function->comment = $comment;
$function->type = T_FUNCTION;
$function->parameters = new PGPList();
Expand Down