Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit8189574

Browse files
committed
add note on return values when null is passed to a data transformer's transform() method
1 parent4c3367f commit8189574

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

‎cookbook/form/data_transformers.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,12 @@ for converting to and from the issue number and the ``Issue`` object::
9797
If you want a new issue to be created when an unknown number is entered, you
9898
can instantiate it rather than throwing the ``TransformationFailedException``.
9999

100+
..note::
101+
102+
When ``null`` is passed to the ``transform()`` method, your transformer
103+
should return an equivalent value of the type it is transforming to (e.g.
104+
an empty string, 0 for integers or 0.0 for floats).
105+
100106
Using the Transformer
101107
---------------------
102108

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp