Skip to content

Add possible parameter values for the field function documentation and error message #121

@Liblastic

Description

@Liblastic

docblock example
@param string $new_lines New line handling way. Possible values: 'wpautop', 'br', ''.

Error message suggestion:
For example ( new Textarea( 'test' ) )->set_new_lines( 'wrong-parameter-value' ) could return error message:

throw new \Geniem\ACF\Exception( 'Geniem\ACF\Textarea: set_new_lines() does not accept argument "' . $new_lines . ' Possible values' . implode( $possible_values, ', ' ) . '"' );

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions