Fix bug in LocalStatus so that it writes out the header line for

folder creation
This commit is contained in:
John Goerzen 2008-03-03 12:57:56 -06:00
parent d11c9305ba
commit aaf9478535
2 changed files with 3 additions and 1 deletions

View File

@ -1,5 +1,5 @@
# Local status cache virtual folder
# Copyright (C) 2002 - 2007 John Goerzen
# Copyright (C) 2002 - 2008 John Goerzen
# <jgoerzen@complete.org>
#
# This program is free software; you can redistribute it and/or modify

View File

@ -18,6 +18,7 @@
from Base import BaseRepository
from offlineimap import folder
import offlineimap.folder.LocalStatus
import os, re
class LocalStatusRepository(BaseRepository):
@ -39,6 +40,7 @@ class LocalStatusRepository(BaseRepository):
def makefolder(self, foldername):
# "touch" the file, truncating it.
file = open(self.getfolderfilename(foldername), "wb")
file.write(offlineimap.folder.LocalStatus.magicline + '\n')
file.close()
# Invalidate the cache.
self.folders = None