@@ -67,32 +67,32 @@ func NewLevelQueueByteFIFO(dataDir string) (*LevelQueueByteFIFO, error) {
67
67
}
68
68
69
69
// PushFunc will push data into the fifo
70
- func (q * LevelQueueByteFIFO ) PushFunc (data []byte , fn func () error ) error {
70
+ func (fifo * LevelQueueByteFIFO ) PushFunc (data []byte , fn func () error ) error {
71
71
if fn != nil {
72
72
if err := fn (); err != nil {
73
73
return err
74
74
}
75
75
}
76
- return q .internal .LPush (data )
76
+ return fifo .internal .LPush (data )
77
77
}
78
78
79
79
// Pop pops data from the start of the fifo
80
- func (q * LevelQueueByteFIFO ) Pop () ([]byte , error ) {
81
- data , err := q .internal .RPop ()
80
+ func (fifo * LevelQueueByteFIFO ) Pop () ([]byte , error ) {
81
+ data , err := fifo .internal .RPop ()
82
82
if err != nil && err != levelqueue .ErrNotFound {
83
83
return nil , err
84
84
}
85
85
return data , nil
86
86
}
87
87
88
88
// Close this fifo
89
- func (q * LevelQueueByteFIFO ) Close () error {
90
- return q .internal .Close ()
89
+ func (fifo * LevelQueueByteFIFO ) Close () error {
90
+ return fifo .internal .Close ()
91
91
}
92
92
93
93
// Len returns the length of the fifo
94
- func (q * LevelQueueByteFIFO ) Len () int64 {
95
- return q .internal .Len ()
94
+ func (fifo * LevelQueueByteFIFO ) Len () int64 {
95
+ return fifo .internal .Len ()
96
96
}
97
97
98
98
func init () {
0 commit comments