export function getCursor ( record , sortField ) { return Buffer . from ( [ record [ sortField ] , record . _id ] . join ( ':' ) ) . toString ( 'base64' ) ; } export function parseCursor ( cursor ) { return Buffer . from ( cursor , 'base64' ) . toString ( 'ascii' ) . split ( ':' ) ; }