[Affelio-cvs 26] CVS update: affelio/lib/Affelio/Managing

Back to archive index

Tadashi Okoshi slash****@users*****
2005年 6月 17日 (金) 13:35:40 JST


Index: affelio/lib/Affelio/Managing/ApplicationManager.pm
diff -u affelio/lib/Affelio/Managing/ApplicationManager.pm:1.1.1.1 affelio/lib/Affelio/Managing/ApplicationManager.pm:1.2
--- affelio/lib/Affelio/Managing/ApplicationManager.pm:1.1.1.1	Tue Jun 14 12:53:29 2005
+++ affelio/lib/Affelio/Managing/ApplicationManager.pm	Fri Jun 17 13:35:40 2005
@@ -6,7 +6,7 @@
 #    http://affelio.jp/ (Japan)
 #    http://affelio.jp/ (USA and other area)
 #
-# $Id: ApplicationManager.pm,v 1.1.1.1 2005/06/14 03:53:29 slash5234 Exp $
+# $Id: ApplicationManager.pm,v 1.2 2005/06/17 04:35:40 slash5234 Exp $
 
 package Affelio::Managing::ApplicationManager;
 {
@@ -176,15 +176,11 @@
 	debug_print("AppManager::check_table: table = [".$my_table_name."]");
 
 	my $query = "SELECT * FROM " . $my_table_name;
-	my $sth = $af->{db}->prepare($query);
-	if($sth){
-
-	    #############################################
-	    #Table already exists. End.
-	    $sth->execute();
-	    debug_print("AppManager::check_table: Table already exists.");
-
-	}else{
+	eval{
+	    my $sth = $af->{db}->prepare($query);
+	    my @dummy = $sth->execute();
+	};
+	if($@){
 	    #############################################
 	    #Table of this application does not exist!
 	    #Thus, we will make the table
@@ -281,6 +277,7 @@
 	opendir(DIR, "$af->{cfg_dir}/apps");
 	while (defined($app_dir = readdir(DIR))) {
 	    if(($app_dir ne '.') && ($app_dir ne '..') 
+	       && ($app_dir ne 'index.html') 
 	       && ($app_dir ne 'sampleapp') && ($app_dir ne 'CVS')){
 
 		##################################


Affelio-cvs メーリングリストの案内
Back to archive index