mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-17 23:00:14 +00:00
Add eslint rule and fix as many issues as possible
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { Schema, model, Types } from 'mongoose';
|
||||
import { Schema, Types, model } from "mongoose";
|
||||
|
||||
export interface IAPIKeyData {
|
||||
name: string;
|
||||
@@ -12,30 +12,30 @@ const apiKeyDataSchema = new Schema<IAPIKeyData>(
|
||||
{
|
||||
name: {
|
||||
type: String,
|
||||
required: true
|
||||
required: true,
|
||||
},
|
||||
user: {
|
||||
type: Schema.Types.ObjectId,
|
||||
ref: 'User',
|
||||
required: true
|
||||
ref: "User",
|
||||
required: true,
|
||||
},
|
||||
lastUsed: {
|
||||
type: Date
|
||||
type: Date,
|
||||
},
|
||||
expiresAt: {
|
||||
type: Date
|
||||
type: Date,
|
||||
},
|
||||
secretHash: {
|
||||
type: String,
|
||||
required: true,
|
||||
select: false
|
||||
}
|
||||
select: false,
|
||||
},
|
||||
},
|
||||
{
|
||||
timestamps: true
|
||||
timestamps: true,
|
||||
}
|
||||
);
|
||||
|
||||
const APIKeyData = model<IAPIKeyData>('APIKeyData', apiKeyDataSchema);
|
||||
const APIKeyData = model<IAPIKeyData>("APIKeyData", apiKeyDataSchema);
|
||||
|
||||
export default APIKeyData;
|
||||
|
||||
Reference in New Issue
Block a user