1
0
Fork 0
mirror of https://github.com/Eggbertx/gochan.git synced 2025-08-03 03:36:22 -07:00

Clean up connect.go a little and update version for release

This commit is contained in:
Eggbertx 2023-03-27 20:11:58 -07:00
parent 881a87c6b1
commit e14e1f176b
6 changed files with 15 additions and 10 deletions

View file

@ -1,6 +1,6 @@
{
"name": "gochan.js",
"version": "3.5.0",
"version": "3.5.1",
"description": "",
"type": "module",
"source": "js/gochan.js",

View file

@ -7,6 +7,6 @@
<h1>404: File not found</h1>
<img src="./lol 404.gif" border="0" alt="">
<p>The requested file could not be found on this server.</p>
<hr/>Site powered by <a href="https://github.com/gochan-org/gochan" target="_blank">Gochan</a> v3.5.0
<hr/>Site powered by <a href="https://github.com/gochan-org/gochan" target="_blank">Gochan</a> v3.5.1
</body>
</html>

View file

@ -7,6 +7,6 @@
<h1>Error 500: Internal Server error</h1>
<img src="./server500.gif" border="0" alt="">
<p>The server encountered an error while trying to serve the page, and we apologize for the inconvenience. The <a href="https://en.wikipedia.org/wiki/Idiot">system administrator</a> will try to fix things as soon they get around to it, whenever that is. Hopefully soon.</p>
<hr/>Site powered by <a href="https://github.com/gochan-org/gochan" target="_blank">Gochan</a> v3.5.0
<hr/>Site powered by <a href="https://github.com/gochan-org/gochan" target="_blank">Gochan</a> v3.5.1
</body>
</html>

View file

@ -7,6 +7,6 @@
<h1>Error 502: Bad gateway</h1>
<img src="./server500.gif" border="0" alt="">
<p>The server encountered an error while trying to serve the page, and we apologize for the inconvenience. The <a href="https://en.wikipedia.org/wiki/Idiot">system administrator</a> will try to fix things as soon they get around to it, whenever that is. Hopefully soon.</p>
<hr/>Site powered by <a href="https://github.com/gochan-org/gochan" target="_blank">Gochan</a> v3.5.0
<hr/>Site powered by <a href="https://github.com/gochan-org/gochan" target="_blank">Gochan</a> v3.5.1
</body>
</html>

View file

@ -90,9 +90,8 @@ func tmpSqlAdjust() error {
return err
}
rows, err := QuerySQL(
`SELECT TABLE_NAME FROM information_schema.TABLES WHERE TABLE_SCHEMA = ?`,
criticalConfig.DBname)
query = `SELECT TABLE_NAME FROM information_schema.TABLES WHERE TABLE_SCHEMA = ?`
rows, err := QuerySQL(query, criticalConfig.DBname)
if err != nil {
return err
}
@ -114,7 +113,10 @@ func tmpSqlAdjust() error {
if err != nil {
return err
}
_, err = ExecSQL(`ALTER TABLE DBPREFIXwordfilters ADD COLUMN IF NOT EXISTS board_dirs varchar(255) DEFAULT '*'`)
query = `ALTER TABLE DBPREFIXwordfilters ADD COLUMN IF NOT EXISTS board_dirs varchar(255) DEFAULT '*'`
if _, err = ExecSQL(query); err != nil {
return err
}
case "sqlite3":
_, err = ExecSQL(`PRAGMA foreign_keys = ON`)
if err != nil {
@ -126,7 +128,10 @@ func tmpSqlAdjust() error {
return err
}
if numColumns == 0 {
_, err = ExecSQL(`ALTER TABLE DBPREFIXwordfilters ADD COLUMN board_dirs varchar(255) DEFAULT '*'`)
query = `ALTER TABLE DBPREFIXwordfilters ADD COLUMN board_dirs varchar(255) DEFAULT '*'`
if _, err = ExecSQL(query); err != nil {
return err
}
}
}

View file

@ -1 +1 @@
3.5.0
3.5.1