/// <reference path="../pb_data/types.d.ts" />
migrate((db) => {
  const dao = new Dao(db)
  const collection = dao.findCollectionByNameOrId("kao3uf79lkj9apb")

  collection.listRule = "\"eidph18vu0r30yi\" = @request.auth.id"

  return dao.saveCollection(collection)
}, (db) => {
  const dao = new Dao(db)
  const collection = dao.findCollectionByNameOrId("kao3uf79lkj9apb")

  collection.listRule = "@request.data.field.item_via_field.id = @request.auth.id"

  return dao.saveCollection(collection)
})
