Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 299620

Convert '_none' option to a constant, deprecate form_select_options() and form_get_options() and move them to a new class

$
0
0

Problem/Motivation

The string '_none' is repeated throughout the module and tests, using a constant makes it easier to refactor.

Steps to reproduce

NA

Proposed resolution

  1. Convert _none to a constant.
  2. Move form_select_options() to a helper class.
  3. Move form_get_options() to a helper class.

Remaining tasks

Review

User interface changes

API changes

String '_none' is converted to constant.
form_select_options() and form_get_options() are moved as class methods in \Drupal\Core\Form\FormOptionsHelper

Data model changes

NA

Release notes snippet

NA


Viewing all articles
Browse latest Browse all 299620

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>