• Resolved simonvw

    (@simonvw)


    Hi,

    With 2fas plugin installed a Fatal Error is thrown when using wp cli. The same error is thrown with every command.

    Fatal error: Uncaught Error: Class 'TwoFAS\TwoFAS\Http\Action_Index' not found in /<path-to-wordpress-install>/wp-content/plugins/2fas/routes.php:17

    Adding this in twofas.php solves the problem:

    
    if (php_sapi_name() === 'cli') {
    	return;
    }
    

    Could this be fixed?

Viewing 3 replies - 1 through 3 (of 3 total)
  • I’ve encountered same problem, I hope the error will be fixed soon because of security reasons for our client.

    Plugin Author 2FAS

    (@2fas)

    We fixed this issue in 3.0.2 version of our plugin.

    Thread Starter simonvw

    (@simonvw)

    The issue is indeed fixed in 3.0.2. Thanks for solving this on a short notice!

    For the future it would be very helpful if I could rollback to the previous version while waiting for a fix. This would prevent me from having to turn off 2fas on our client website altogether.

    Is there a reason that only “dev-trunk” and the latest version are available on wpackagist?

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Fatal error when using wp-cli’ is closed to new replies.