- $gen->initTheme("/dev/null"); # theme is not needed because CSS is not emitted
- $gen->initLanguage($langfile); # must come after initTheme
+ if ($data_dir){
+ # new style, requires a real theme, but has no effect
+ $gen->initTheme($data_dir->getThemePath("seashell.theme"));
+ } else {
+ # old style, anything works.
+ $gen->initTheme("/dev/null");
+ }
+ $gen->loadLanguage($langfile); # must come after initTheme