fmt
This commit is contained in:
parent
46e022c731
commit
5c1ff3e114
@ -64,11 +64,11 @@ func (ts *TootFSStorage) TootExists(t toot.Toot) bool {
|
||||
func (ts *TootFSStorage) StoreToot(t toot.Toot) error {
|
||||
path := t.DiskStoragePath()
|
||||
full := ts.root + "/" + path
|
||||
dir := filepath.Dir(full)
|
||||
err := os.MkdirAll(dir, 0755)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
dir := filepath.Dir(full)
|
||||
err := os.MkdirAll(dir, 0755)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return ioutil.WriteFile(full, t.Original, 0644)
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user