/// <reference path="../pb_data/types.d.ts" />
migrate((app) => {
  const collection = app.findCollectionByNameOrId("pbc_3958665665")

  // add field
  collection.fields.addAt(5, new Field({
    "hidden": false,
    "id": "json1321596786",
    "maxSize": 0,
    "name": "benefits_list",
    "presentable": false,
    "required": false,
    "system": false,
    "type": "json"
  }))

  return app.save(collection)
}, (app) => {
  const collection = app.findCollectionByNameOrId("pbc_3958665665")

  // remove field
  collection.fields.removeById("json1321596786")

  return app.save(collection)
})
