Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Currently variable names are like social_stats.cron_settings.social_stats_url_root
, since in Drupal 8 config variable names starts with module name, so we can safely name variable social_stats.cron_settings.url_root
.
Added default values to some config variables in config schema file, $config->get()
takes only one argument, removed second arg from get calls, default values for those variables is stored in config schema file.
Removed old settings form code.
Comment | File | Size | Author |
---|---|---|---|
#8 | 2737157-interdiff-1-5.txt | 2.6 KB | Sharique |
#6 | remove_old_config_code-2737157-5.patch | 13.97 KB | Sharique |
Comments
Comment #2
vijaycs85I would go with
Comment #3
Sharique CreditAttribution: Sharique as a volunteer commentedComment #4
vijaycs85nitpick:
$content_type_settings = \Drupal::config('social_stats.settings).get('content_types);
then
we can check if (isset($content_type_settings[$type->id()]))
This will make the if condition lighter.
Comment #5
vijaycs85Anyway, it looks much better.
Comment #6
Sharique CreditAttribution: Sharique as a volunteer commentedDid that nitpick and bit more.
Comment #7
AjitSThank you @vijaycs85 for the reviews!
@Sharique : Could you please attach an interdiff so that the review is easy?
Comment #8
Sharique CreditAttribution: Sharique as a volunteer commented@Ajit here is interdiff, I already committed this code, don't know why it is not showing here, also not showing in commit list page https://www.drupal.org/node/2080003/commits.
Comment #9
AjitSThank you! I'd assume that the commit not showing up here should be a temporary issue. However, if this continues we should create an issue in the webmasters issue queue.
Marking this issue as fixed, with appropriate credits. Thank you again!