Get config.php variable in a 'non-widget' file but in a widget

In a widget, if I use <?=c::get('myvariable')?> to get a variable from my config.php in mywidgetname.html.php file, the variable info is retrieved and I can use it

But if I use the same code in another php file within my widget folder, say lib.php, it does not get the information.

Kirby 2.5.2

Anyone any ideas?

How is your lib.php loaded? Do you include or require it somewhere?

I am using a require to the php file… but of course it was a typo :cry:
Thanks for your help, it is appreciated even if it was me being stupid.