Skip to content

Commit 4804f7a

Browse files
fixing cursor assumption bug
1 parent 30d6e08 commit 4804f7a

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

models/personas.lisp

+3-1
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,9 @@
162162
(:coerce-to (:pluck (:get-all (:table "boards_personas_link") persona-id :index (db-index "boards_personas_link" "to")) (list "board_id" "to")) "array")
163163
(:coerce-to (:pluck (:get-all (:table "boards_personas_link") persona-id :index (db-index "boards_personas_link" "from")) (list "board_id" "to")) "array"))))
164164
(cursor (r:run sock query-boards))
165-
(board-links (r:to-array sock cursor))
165+
(board-links (if cursor
166+
(r:to-array sock cursor)
167+
#()))
166168
(nil (r:stop sock cursor))
167169
(query-to (r:r (:delete (:get-all (:table "boards_personas_link") persona-id :index (db-index "boards_personas_link" "to")))))
168170
(query-from (r:r (:delete (:get-all (:table "boards_personas_link") persona-id :index (db-index "boards_personas_link" "from")))))

0 commit comments

Comments
 (0)