[wp-trac] [WordPress Trac] #57725: Use of rand() function instead of wp_rand()

WordPress Trac noreply at wordpress.org
Thu Feb 16 14:59:41 UTC 2023


#57725: Use of rand() function instead of wp_rand()
-------------------------------------+-------------------------------------
 Reporter:  haritpanchal             |       Owner:  (none)
     Type:  enhancement              |      Status:  new
 Priority:  normal                   |   Milestone:  Awaiting Review
Component:  Filesystem API           |     Version:
 Severity:  normal                   |  Resolution:
 Keywords:  has-patch has-testing-   |     Focuses:  performance, coding-
  info needs-testing                 |  standards
-------------------------------------+-------------------------------------
Changes (by costdev):

 * keywords:  has-patch => has-patch has-testing-info needs-testing
 * focuses:  coding-standards => performance, coding-standards


Comment:

 Hi @sakibmd, thanks for opening this ticket and for the patch!

 -----

 == Testing Instructions
 These steps define how to test the feature or enhancement, and indicates
 the expected behavior or results.

 === Steps to Test
 1. Apply
 [https://core.trac.wordpress.org/attachment/ticket/57725/57725.diff the
 patch].
 2. Navigate to `Appearance > Themes` and ensure that a classic theme is
 activated.
 3. Navigate to `Appearance > Theme File Editor`.
 4. ✅ Open the `functions.php` file and add `echo 'Howdy, admin!';`. Click
 **Update File**.
 5. ✅ Remove the `;` and click **Update File**.
 6. Navigate to `Plugins > Plugin File Editor`.
 7. ✅ Open the main plugin file for an active plugin and add `echo 'Howdy,
 admin!';`. Click **Update File**.
 8. ✅ Remove the `;` and click **Update File**.

 === Expected Results
 Lists each expected result or behavior, i.e. what should happen when
 running the test(s):

 - ✅ The theme file should be updated successfully.
 - ✅ The theme file should fail to update.
 - ✅ The plugin file should be updated successfully.
 - ✅ The plugin file should fail to update.

 === Notes
 - Adding `has-testing-info` and `needs-testing`.
 - Adding `performance` focus and pinging @flixos90 for thoughts regarding
 performance.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/57725#comment:3>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list