From 7758c9eda5f3b39bfcf494f71ad958581f957939 Mon Sep 17 00:00:00 2001 From: Jacek Kowalski <Jacek@jacekk.info> Date: Mon, 17 Sep 2012 09:58:08 +0000 Subject: [PATCH] 1. Uwzględnienie w pliku UPGRADE skryptu test.php 2. Zmiana wersji bota na 2.5 w związku z poprzednimi poprawkami. --- class/BotSession.php | 8 +++++++- 1 files changed, 7 insertions(+), 1 deletions(-) diff --git a/class/BotSession.php b/class/BotSession.php index 9099b8a..494f377 100644 --- a/class/BotSession.php +++ b/class/BotSession.php @@ -55,6 +55,12 @@ $version = 1; } + if($version < 3) { + $this->PDO->query('DELETE FROM data WHERE class IS NULL AND name=\'user_struct\''); + $this->PDO->query('INSERT OR REPLACE INTO data (class, name, value) VALUES (\'\', \'_version\', 3)'); + $version = 3; + } + return; } @@ -83,7 +89,7 @@ $this->PDO->beginTransaction(); $st = $this->PDO->prepare('INSERT OR REPLACE INTO data (class, name, value) VALUES (?, ?, ?)'); - $st->execute(array('', '_version', 1)); + $st->execute(array('', '_version', 2)); foreach($files as $file) { $data = unserialize(file_get_contents($file)); -- Gitblit v1.9.1