1
0
mirror of https://github.com/jhillyerd/inbucket.git synced 2025-12-18 18:17:03 +00:00

Gorilla is fully operational

- All mailbox actions working: index, list, show, html, source and delete
 - Cleaned up extra files from Revel
 - Took a guess at install process for README.md

This closes #4
This commit is contained in:
James Hillyerd
2012-10-21 13:42:34 -07:00
parent 71bb52a64a
commit 2c7419c661
14 changed files with 110 additions and 200 deletions

View File

@@ -160,8 +160,6 @@ func (m *Message) gobPath() string {
}
func (m *Message) rawPath() string {
Trace(m.mailbox.path)
Trace(m.Id)
return filepath.Join(m.mailbox.path, m.Id+".raw")
}
@@ -261,10 +259,12 @@ func (m *Message) Close() error {
// Delete this Message from disk by removing both the gob and raw files
func (m *Message) Delete() error {
Trace("Deleting %v", m.gobPath())
err := os.Remove(m.gobPath())
if err != nil {
return err
}
Trace("Deleting %v", m.rawPath())
return os.Remove(m.rawPath())
}