Issue #3409388 by quietone, smustgrave: Remove usage of forum module from comments and strings

merge-requests/5578/merge
catch 2024-01-11 20:47:56 +00:00
parent 2c6bb82a74
commit 225e93019d
9 changed files with 22 additions and 33 deletions

View File

@ -68,11 +68,11 @@ use Drupal\Component\Graph\Graph;
*
* If an extension author wants a configuration entity to depend on something
* that is not calculable then they can add these dependencies to the enforced
* dependencies key. For example, the Forum module provides the forum node type
* and in order for it to be deleted when the forum module is uninstalled it has
* an enforced dependency on the module. The dependency on the Forum module can
* not be calculated since there is nothing inherent in the state of the node
* type configuration entity that depends on functionality provided by the Forum
* dependencies key. For example, a custom module that provides a node type can
* have that type deleted when the module is uninstalled, if it has an enforced
* dependency on the module. The dependency on the custom module can not be
* calculated since there is nothing inherent in the state of the node type
* configuration entity that depends on functionality provided by the custom
* module.
*
* Once declared properly, dependencies are saved to the configuration entity's

View File

@ -523,8 +523,6 @@ use Drupal\node\Entity\NodeType;
* general information about configuration.)
*
* There are several good examples of this in Drupal Core:
* - The Forum module defines a content type in node.type.forum.yml and a
* vocabulary in taxonomy.vocabulary.forums.yml
* - The Book module defines a content type in node.type.book.yml
* - The Standard install profile defines Page and Article content types in
* node.type.page.yml and node.type.article.yml, a Tags vocabulary in

View File

@ -40,7 +40,7 @@ interface InfoParserInterface {
* can contain "x" as a wildcard. Examples: (>=8.22, <8.28), (8.x-3.x).
* - package: The name of the package of modules this module belongs to.
*
* See forum.info.yml for an example of a module .info.yml file.
* See node.info.yml for an example of a module .info.yml file.
*
* Information stored in a theme .info.yml file:
* - screenshot: Path to screenshot relative to the theme's .info.yml file.

View File

@ -1222,15 +1222,7 @@ function hook_page_bottom(array &$page_bottom) {
* rendered output.
* - pattern: A regular expression pattern to be used to allow this theme
* implementation to have a dynamic name. The convention is to use __ to
* differentiate the dynamic portion of the theme. For example, to allow
* forums to be themed individually, the pattern might be: 'forum__'. Then,
* when the forum is rendered, following render array can be used:
* @code
* $render_array = array(
* '#theme' => array('forum__' . $tid, 'forum'),
* '#forum' => $forum,
* );
* @endcode
* differentiate the dynamic portion of the theme.
* - preprocess functions: A list of functions used to preprocess this data.
* Ordinarily this won't be used; it's automatically filled in. By default,
* for a module this will be filled in as template_preprocess_HOOK. For
@ -1256,13 +1248,13 @@ function hook_page_bottom(array &$page_bottom) {
*/
function hook_theme($existing, $type, $theme, $path) {
return [
'forum_display' => [
'variables' => ['forums' => NULL, 'topics' => NULL, 'parents' => NULL, 'tid' => NULL, 'sortby' => NULL, 'forum_per_page' => NULL],
'my_module_display' => [
'variables' => ['my_modules' => NULL, 'topics' => NULL, 'parents' => NULL, 'tid' => NULL, 'sortby' => NULL, 'my_module_per_page' => NULL],
],
'forum_list' => [
'variables' => ['forums' => NULL, 'parents' => NULL, 'tid' => NULL],
'my_module_list' => [
'variables' => ['my_modules' => NULL, 'parents' => NULL, 'tid' => NULL],
],
'forum_icon' => [
'my_module_icon' => [
'variables' => ['new_posts' => NULL, 'num_posts' => 0, 'comment_mode' => 0, 'sticky' => 0],
],
'status_report' => [
@ -1315,10 +1307,10 @@ function hook_theme($existing, $type, $theme, $path) {
* @see \Drupal\Core\Theme\Registry::processExtension()
*/
function hook_theme_registry_alter(&$theme_registry) {
// Kill the next/previous forum topic navigation links.
foreach ($theme_registry['forum_topic_navigation']['preprocess functions'] as $key => $value) {
if ($value == 'template_preprocess_forum_topic_navigation') {
unset($theme_registry['forum_topic_navigation']['preprocess functions'][$key]);
// Kill the next/previous my_module topic navigation links.
foreach ($theme_registry['my_module_topic_navigation']['preprocess functions'] as $key => $value) {
if ($value == 'template_preprocess_my_module_topic_navigation') {
unset($theme_registry['my_module_topic_navigation']['preprocess functions'][$key]);
}
}
}

View File

@ -6,8 +6,8 @@
*
* When installed, the Comment module creates a field that facilitates a
* discussion board for each Drupal entity to which a comment field is attached.
* Users can post comments to discuss a forum topic, story, collaborative
* book page, user etc.
* Users can post comments to discuss a story, collaborative book page, user
* etc.
*/
use Drupal\comment\CommentInterface;

View File

@ -161,7 +161,7 @@ class FieldStorageConfig extends ConfigEntityBase implements FieldStorageConfigI
* are no remaining fields using them. If multiple modules provide bundles
* which need to use the same field storage then setting this to TRUE will
* preserve the field storage regardless of what happens to the bundles. The
* classic use case for this is node body field storage since Book, Forum, the
* classic use case for this is node body field storage since Book, the
* Standard profile and bundle (node type) creation through the UI all use
* same field storage.
*

View File

@ -5,7 +5,6 @@
* Records which users have read which content.
*
* @todo
* - Generic helper for _forum_user_last_visit() + history_read().
* - Generic helper for node_mark().
*/

View File

@ -210,8 +210,8 @@ class NodeTypeTest extends NodeTestBase {
$locked = \Drupal::state()->get('node.type.locked');
$locked['default'] = 'default';
\Drupal::state()->set('node.type.locked', $locked);
// Call to flush all caches after installing the forum module in the same
// way installing a module through the UI does.
// Call to flush all caches after installing the node_test_config module in
// the same way installing a module through the UI does.
$this->resetAll();
$this->drupalGet('admin/structure/types/manage/default');
$this->assertSession()->linkNotExists('Delete');

View File

@ -148,7 +148,7 @@ function path_field_widget_single_element_form_alter(&$element, FormStateInterfa
}
if ($field_name === 'path') {
$element['value']['#description'] = t('Specify the existing path you wish to alias. For example: /node/28, /forum/1, /taxonomy/term/1.');
$element['value']['#description'] = t('Specify the existing path you wish to alias. For example: /node/28, /media/1, /taxonomy/term/1.');
}
if ($field_name === 'alias') {