mirror of
				https://gitee.com/gitea/gitea
				synced 2025-11-04 08:30:25 +08:00 
			
		
		
		
	Bug fix #45
This commit is contained in:
		@@ -43,9 +43,9 @@ func NewTestEngine(x *xorm.Engine) (err error) {
 | 
			
		||||
	case "postgres":
 | 
			
		||||
		x, err = xorm.NewEngine("postgres", fmt.Sprintf("user=%s password=%s dbname=%s sslmode=%s",
 | 
			
		||||
			DbCfg.User, DbCfg.Pwd, DbCfg.Name, DbCfg.SslMode))
 | 
			
		||||
	case "sqlite3":
 | 
			
		||||
		os.MkdirAll(path.Dir(DbCfg.Path), os.ModePerm)
 | 
			
		||||
		x, err = xorm.NewEngine("sqlite3", DbCfg.Path)
 | 
			
		||||
	// case "sqlite3":
 | 
			
		||||
	// 	os.MkdirAll(path.Dir(DbCfg.Path), os.ModePerm)
 | 
			
		||||
	// 	x, err = xorm.NewEngine("sqlite3", DbCfg.Path)
 | 
			
		||||
	default:
 | 
			
		||||
		return fmt.Errorf("Unknown database type: %s\n", DbCfg.Type)
 | 
			
		||||
	}
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user