[wp-trac] [WordPress Trac] #56738: Use require_once instead of require to load block files
WordPress Trac
noreply at wordpress.org
Fri Oct 7 01:56:45 UTC 2022
#56738: Use require_once instead of require to load block files
------------------------------+----------------------
Reporter: aristath | Owner: desrosj
Type: defect (bug) | Status: closed
Priority: normal | Milestone: 6.1
Component: Build/Test Tools | Version:
Severity: normal | Resolution: fixed
Keywords: has-patch commit | Focuses:
------------------------------+----------------------
Changes (by desrosj):
* status: assigned => closed
* resolution: => fixed
Comment:
In [changeset:"54406" 54406]:
{{{
#!CommitTicketReference repository="" revision="54406"
Build/Test Tools: Use `require_once` instead of `require`.
The `sync-stable-blocks.js` file is used to compile the contents of
`require-dynamic-blocks.php`, which includes the PHP files required for
dynamic Core blocks.
Since these files define PHP functions, `require_once` should be used
instead of `require` to guard against fatal errors.
Follow up to [53688].
Props aristath, SergeyBiryukov, desrosj.
Fixes #56738. See #56179.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/56738#comment:4>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list