• Resolved yacinesahli

    (@yacinesahli)


    Hello,
    When I put a course as free without registration, if not logged in the user will get a blank page with a 401 in the browser console.

    api call with error 401:
    `https://example.com/wp-json/wp/v2/users/me?context=edit&_locale=use
    error message:
    {“code”:”rest_not_logged_in”,”message”:”You are not currently logged in.”,”data”:{“status”:401}}

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Support Aashil Bijukshe

    (@lihsaa)

    Hello @yacinesahli

    Some of the variables might depend upon if a user is logged in. So when accessing a public course in guest mode this might throw but still users can go through course contents. Have you added lessons or quizzes to the course?

    Thank You

    Thread Starter yacinesahli

    (@yacinesahli)

    Yes, I added lessons and quizz.
    If the user creates an account and is logged-in, the lessons and quiz work perfectly

    Plugin Support Aashil Bijukshe

    (@lihsaa)

    Can you please provide screenrecord on this so that we can look through it ? As it seems to work normally on our side. Thanks

    Thread Starter yacinesahli

    (@yacinesahli)

    Here is the url of the websites courses I am testing on.
    There is only one course u can try there without registering.

    https://cathychinese.com/courses/

    Plugin Support Aashil Bijukshe

    (@lihsaa)

    Hello @yacinesahli

    After looking through your site, it seems like the problem is with Litespeed cache plugin. Try after deactivating the plugin if it will resolve the issue or not. Here is the link to a screenshot.

    Thank You

    Thread Starter yacinesahli

    (@yacinesahli)

    I added the course url path to the cache exclusion in litespeed and now it works.
    Thank you, I think I’ll add all masteriyo related urls to the cache exclude.

    Here is the setting for other users

    Add ^/learn/course
    in Litespeed Cache > Cache > [4] Excludes >Do not cache URIs

    • This reply was modified 1 year, 5 months ago by yacinesahli.
    • This reply was modified 1 year, 5 months ago by yacinesahli.
Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Course without registration 401’ is closed to new replies.