I am trying to create a custom service and call it from a controller that is being used on a route. I use simple code, so I think I am missing something
The membership service: https://gist.github.com/betz/6e0cb7ce2712793711d4c9ed99a3a697
The error I get:
RuntimeException: Controller "Drupal\hsbxl_members\Controller\Test::test()" requires that you provide a value for the "$container" argument (because there is no default value or because there is a non optional argument after this one). in Drupal\Core\Controller\ControllerResolver->doGetArguments() (line 165 of /var/www/drupalvm/web/core/lib/Drupal/Core/Controller/ControllerResolver.php).
So it seems the ContainerInterface $container is missing when the controller is being initiated. But how do i do this? Confused.