Title: Plugin crashes with undefined function is_plugin_active
Last modified: May 30, 2021

---

# Plugin crashes with undefined function is_plugin_active

 *  Resolved [frankieandshadow](https://wordpress.org/support/users/frankieandshadow/)
 * (@frankieandshadow)
 * [4 years, 12 months ago](https://wordpress.org/support/topic/plugin-crashes-with-undefined-function-is_plugin_active/)
 * A recent update (probably the one for [https://wordpress.org/support/topic/fatal-error-when-relevanssi-is-not-activated/](https://wordpress.org/support/topic/fatal-error-when-relevanssi-is-not-activated/))
   is getting a runtime PHP fatal error “Call to undefined function is_plugin_active()”
   when making a REST query which used to work. (Relevnasi is active, but it never
   gets that far as the function supposedly to test whether it is or not apparently
   does not exist; perhaps it is called too early?).
 * I replaced `if (!is_plugin_active( 'relevanssi/relevanssi.php' ) && !is_plugin_active('
   relevanssi-premium/relevanssi.php' )) {`with`if (FALSE) {` on the offending line
   rest-api-for-relevanssi.php:64 and it works again.
    -  This topic was modified 4 years, 12 months ago by [frankieandshadow](https://wordpress.org/support/users/frankieandshadow/).

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Author [Sergiy Dzysyak](https://wordpress.org/support/users/dzysyak/)
 * (@dzysyak)
 * [4 years, 12 months ago](https://wordpress.org/support/topic/plugin-crashes-with-undefined-function-is_plugin_active/#post-14500731)
 * The bug is fixed with the last update that was just uploaded.
 * Thank you for the report.
 *  Thread Starter [frankieandshadow](https://wordpress.org/support/users/frankieandshadow/)
 * (@frankieandshadow)
 * [4 years, 12 months ago](https://wordpress.org/support/topic/plugin-crashes-with-undefined-function-is_plugin_active/#post-14508500)
 * Thank you! I can confirm it is now working again for me.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Plugin crashes with undefined function is_plugin_active’ is closed to
new replies.

 * ![](https://ps.w.org/rest-api-for-relevanssi/assets/icon-256x256.png?rev=2370302)
 * [REST API for Relevanssi](https://wordpress.org/plugins/rest-api-for-relevanssi/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/rest-api-for-relevanssi/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/rest-api-for-relevanssi/)
 * [Active Topics](https://wordpress.org/support/plugin/rest-api-for-relevanssi/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/rest-api-for-relevanssi/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/rest-api-for-relevanssi/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [frankieandshadow](https://wordpress.org/support/users/frankieandshadow/)
 * Last activity: [4 years, 12 months ago](https://wordpress.org/support/topic/plugin-crashes-with-undefined-function-is_plugin_active/#post-14508500)
 * Status: resolved