in the galleries/global.php file.
change line 15:
'html_prefix' => $GLOBALS['wa_settings']['pg_root'] . substr($abs_file, strpos($abs_file, '/galleries/') + 1) . '/'
to:
'html_prefix' => $GLOBALS['wa_settings']['pg_root'] . substr($abs_file, strrpos($abs_file, '/galleries/') + 1) . '/'