Index: openacs-4/packages/acs-lang/tcl/lang-catalog-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-lang/tcl/lang-catalog-procs.tcl,v diff -u -N -r1.4 -r1.5 --- openacs-4/packages/acs-lang/tcl/lang-catalog-procs.tcl 3 Dec 2002 17:26:54 -0000 1.4 +++ openacs-4/packages/acs-lang/tcl/lang-catalog-procs.tcl 13 Dec 2002 12:30:28 -0000 1.5 @@ -359,17 +359,23 @@ ad_proc -public import_from_all_files_and_cache {} { Loops over all installed and enabled packages that don't already have messages in the database and imports messages from the catalog files of each such package. When this process is done - the message cache is reloaded. + the message cache is reloaded. The proc checks if it has been executed before and will + only execute once. @author Peter Marklund (peter@collaboraid.biz) } { - db_foreach all_enabled_not_loaded_packages {} { - if { [file isdirectory [file join [acs_package_root_dir $package_key] catalog]] } { - lang::catalog::import_from_files $package_key + # Only executed this proc once + if { ![nsv_exists lang_catalog_import_from_all_files_and_cache executed_p] } { + nsv_set lang_catalog_import_from_all_files_and_cache executed_p 1 + + db_foreach all_enabled_not_loaded_packages {} { + if { [file isdirectory [file join [acs_package_root_dir $package_key] catalog]] } { + lang::catalog::import_from_files $package_key + } } - } - lang::message::cache + lang::message::cache + } } ad_proc -private translate {} {