Added story stats and changed db logic