use default null instead of pointer to primary key

This commit is contained in:
sentriz
2019-05-27 11:22:01 +01:00
parent 4b66a84985
commit 601cf560d0
9 changed files with 58 additions and 56 deletions

View File

@@ -26,10 +26,10 @@ func (s *folderStack) Peek() model.Folder {
return (*s)[l-1]
}
func (s *folderStack) PeekID() *int {
func (s *folderStack) PeekID() int {
l := len(*s)
if l == 0 {
return nil
return 0
}
return (*s)[l-1].ID
}