class is Migration

This commit is contained in:
Nikos Kouremenos 2005-12-05 11:44:28 +00:00
parent 7050a346c7
commit 19dc3b9295
2 changed files with 3 additions and 4 deletions

View File

@ -25,7 +25,7 @@ else:
PATH_TO_LOGS_BASE_DIR = os.path.expanduser('~/.gajim/logs')
PATH_TO_DB = os.path.expanduser('~/.gajim/logs.db') # database is called logs.db
class migration:
class Migration:
def __init__(self):
self.constants = logger.Constants()
self.DONE = False
@ -145,7 +145,6 @@ class migration:
show = message_data[0]
message = ':'.join(message_data[1:]) # status msg
# message = decode_string(message)
message = message[:-1] # remove last \n
if not message:
continue
@ -224,5 +223,5 @@ if __name__ == '__main__':
print 'Starting Logs Migration'
print '======================='
print 'Please do NOT run Gajim until this script is over'
m = migration()
m = Migration()
m.migrate()

View File

@ -1469,7 +1469,7 @@ if __name__ == '__main__':
import Queue
q = Queue.Queue(100)
from common import migrate_logs_to_dot9_db
m = migrate_logs_to_dot9_db.migration()
m = migrate_logs_to_dot9_db.Migration()
dialog = dialogs.ProgressDialog(_('Migrating logs...'), _('Please wait while logs are being migrated...'), q)
t = threading.Thread(target = m.migrate, args = (q,))
t.start()