Workers - Bypass Cache on Cookie

Hello,

For instance I wanted to get started with Workers only to bypass cache for logged in users on my site P.S. Am not a coder. To resume :

  1. I added the settings to decrease TTFB using the recommendations here : Reduce TTFB
  2. But doesn’t work well when users are logged in. I was told I need to create a worker to bypass cache based on cookies.
  3. There is a worker already made for WordPresss but my site is using Joomla. Here it is: WP Worker to bypass cache for logged in users
  4. So I got started by going to Workers > Overview > Create a service. I named the service “bypass” and chose “Http-router”, then “create a service”
  5. Then I clicked on “quick edit” and pasted the code in pt. 3 there. After that I modified the code only for the joomla cookie. The red part:
    const BYPASS_COOKIE_PREFIXES = [
    “joomla_user_state”,
    Then “Save and Deploy”
  6. The worker is found here : My Worker
  7. I guess I need to tell CF somewhere that this worker needs to be applied to my domain right ?
    Either my worker isn’t good or I’m doing something wrong since it’s not working.

Thanks for your help !