import { model, Schema } from "mongoose";

export interface IRole {
  name: string;
  priority: number;
}

const schema = new Schema<IRole>(
  {
    name: { type: String },
    priority: { type: Number },
  },
  { toJSON: { versionKey: false } }
);

export default model<IRole>("Role", schema);
