MantisBT: master-2.25 f2239a9a

Author Committer Branch Timestamp Parent
dregad dregad master-2.25 2023-01-04 13:03 master-2.25 91df620c
Changeset

Use date_strtotime() instead of strtotime()

Replace native strtotime() calls by revised date_strtotime() where
relevant, i.e. when date string could be user-provided.

This prevents occurrence of the error described in issue #31866.

It also allows users to submit dates in $g_normal_date_format in the
following situations:

  • REST API: Create a project version (timestamp), Add Issue (due_date)
  • SOAP API: Add/Update Issue (due_date) and Project Version Update
    (date_order)
  • Bug Update, Bug API (due_date)
    NOTE: change to bug_update.php is not strictly not necessary as the
    script is normally only called internally, not directly by users.

TODO: the REST API's documentation should be updated

mod - api/soap/mc_issue_api.php Diff File
mod - api/soap/mc_project_api.php Diff File
mod - bug_update.php Diff File
mod - core/bug_api.php Diff File
mod - core/commands/IssueAddCommand.php Diff File
mod - core/commands/VersionAddCommand.php Diff File