function momentifyTimestamps(
  object,
  keys = ["created_at", "updated_at"],
) {
  object = { ...object };
  for (const timestamp of keys) {
    if (object[timestamp]) {
      object[timestamp] = moment(object[timestamp]);
    }
  }
  return object;
}
// turns string timestamps into moment objects
turns string timestamps into moment objects
turns string timestamps into moment objects
function momentifyTimestamps(
  object,
  keys = ["created_at", "updated_at"],
) {
  object = { ...object };
  for (const timestamp of keys) {
    if (object[timestamp]) {
      object[timestamp] = moment(object[timestamp]);
    }
  }
  return object;
}
function momentifyTimestamps ( object , keys = [ "created_at" , "updated_at" ] , ) { object = { ... object } ; for ( const timestamp of keys ) { if ( object [ timestamp ] ) { object [ timestamp ] = moment ( object [ timestamp ] ) ; } } return object ; }
turns string timestamps into moment objects
turns string timestamps into moment objects