I wasn't sure where to post this but it seems to be a problem with Links so I've chosen here.
I've had an annoying error message for months and having decided to investigate it properly I think I can replicate it now. I have a Forum application that pulls data from Links. I have a global in Forum:
sub {
my $cat_db = GT::SQL->new('/path/to/links/admin/defs')->table('Category');
}
- obviously the global is more complicated than this but I've identified that this is the line causing the problem.
The problem only occurs the first time that the page is viewed after mod_perl is restarted.
This is the error:
A fatal error has occurred:
Please enable debugging in setup for more details.
This is code that is only run for the first time a Category table object is created which is why it only happens after mod_perl is restarted. Is it a bug? Or should I be coding it differently?
I've had an annoying error message for months and having decided to investigate it properly I think I can replicate it now. I have a Forum application that pulls data from Links. I have a global in Forum:
sub {
my $cat_db = GT::SQL->new('/path/to/links/admin/defs')->table('Category');
}
- obviously the global is more complicated than this but I've identified that this is the line causing the problem.
The problem only occurs the first time that the page is viewed after mod_perl is restarted.
This is the error:
A fatal error has occurred:
Can't call method "table" on an undefined value at /path/to/links/admin/Links/Table/Category.pm line 39.
Please enable debugging in setup for more details.
This is code that is only run for the first time a Category table object is created which is why it only happens after mod_perl is restarted. Is it a bug? Or should I be coding it differently?