summaryrefslogtreecommitdiff
path: root/system/db/content.go
diff options
context:
space:
mode:
authorSteve Manuel <nilslice@gmail.com>2016-10-29 17:39:55 -0700
committerSteve Manuel <nilslice@gmail.com>2016-10-29 17:39:55 -0700
commitffa19ffc49ac11c426d29b543e3df26d3de61ec8 (patch)
treedfedf34fda6caf7f3f863233d5b0dccc68001369 /system/db/content.go
parentb1212fa6f48da1d539a73e1bd5a0bf6894b97d7d (diff)
adding db procedures and updating handler for external submissions / pending content
Diffstat (limited to 'system/db/content.go')
-rw-r--r--system/db/content.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/system/db/content.go b/system/db/content.go
index 0b486ba..f3397ba 100644
--- a/system/db/content.go
+++ b/system/db/content.go
@@ -199,6 +199,10 @@ func ContentAll(namespace string) [][]byte {
store.View(func(tx *bolt.Tx) error {
b := tx.Bucket([]byte(namespace))
+ if b == nil {
+ return nil
+ }
+
numKeys := b.Stats().KeyN
posts = make([][]byte, 0, numKeys)