LLMS_Add_On::uninstall()
Verifies the add-on can be uninstalled, and performs the uninstall (permanently deleting its files)
Return Return
(string|WP_Error) Success message or an error object.
Source Source
File: includes/models/model.llms.add-on.php
public function uninstall() { $title = $this->get( 'title' ); if ( ! $this->is_installed() ) { // Translators: %s = Add-on title. return new WP_Error( 'not-installed', sprintf( __( '%s is not installed.', 'lifterlms' ), $title ) ); } if ( $this->is_active() ) { // Translators: %s = Add-on title. return new WP_Error( 'uninstall-active', sprintf( __( '%s is active and cannot be uninstalled.', 'lifterlms' ), $title ) ); } return $this->uninstall_real(); }
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
5.1.1 | Introduced. |