dmchale / disable-json-api

Public repo for the "Disable REST API" WordPress plugin, currently with 90,000+ active installs in the wordpress.org repository
10 stars 9 forks source link

Strict in_array check as per WP coding standards and use WordPress checked #17

Closed tangrufus closed 7 years ago

tangrufus commented 7 years ago
dmchale commented 7 years ago

Rejecting this one only due to personal preference of avoiding the one-liner as it was written here. For readability I kept the function call, and broke up the in_array() and checked() functions into their own lines. I also made sure to include the strict param in in_array(). Commit: https://github.com/dmchale/disable-json-api/commit/66e8cbb84d0503d530e65fd0f8c4fd7ceaf76979