Skip to content

Commit

Permalink
Merge pull request #1038 from cmegahan/patch-1
Browse files Browse the repository at this point in the history
Specify what exceptions are throw for MUST_EXIST
  • Loading branch information
andrewnicols authored Jun 6, 2024
2 parents 19527cc + b8ad28d commit cf7da37
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/apis/core/dml/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ $DB->get_record_sql(

Some methods accept the <tt>$strictness</tt> parameter affecting the method behaviour. Supported modes are specified using the constants:

- <tt>MUST_EXIST</tt> - In this mode, the requested record must exist and must be unique. An exception will be thrown if no record is found or multiple matching records are found.
- <tt>MUST_EXIST</tt> - In this mode, the requested record must exist and must be unique. An exception `dml_missing_record_exception` will be thrown if no record is found or `dml_multiple_records_exception` if multiple matching records are found.
- <tt>IGNORE_MISSING</tt> - In this mode, a missing record is not an error. False boolean is returned if the requested record is not found. If more records are found, a debugging message is displayed.
- <tt>IGNORE_MULTIPLE</tt> - This is not a recommended mode. The function will silently ignore multiple records found and will return just the first one of them.

Expand Down

0 comments on commit cf7da37

Please sign in to comment.