From 9bcd3cde46c457f0f59dbf8694652615ba9b272f Mon Sep 17 00:00:00 2001
From: syuilo <syuilotan@yahoo.co.jp>
Date: Wed, 28 Mar 2018 16:09:49 +0900
Subject: [PATCH] wip

---
 src/api/models/signin.ts            | 5 +++++
 tools/migration/shell.camel-case.js | 7 +++++++
 2 files changed, 12 insertions(+)

diff --git a/src/api/models/signin.ts b/src/api/models/signin.ts
index 262c8707ed..62ee796d85 100644
--- a/src/api/models/signin.ts
+++ b/src/api/models/signin.ts
@@ -7,6 +7,11 @@ export default Signin;
 
 export interface ISignin {
 	_id: mongo.ObjectID;
+	createdAt: Date;
+	userId: mongo.ObjectID;
+	ip: string;
+	headers: any;
+	success: boolean;
 }
 
 /**
diff --git a/tools/migration/shell.camel-case.js b/tools/migration/shell.camel-case.js
index a7e8afcdce..533868cdc4 100644
--- a/tools/migration/shell.camel-case.js
+++ b/tools/migration/shell.camel-case.js
@@ -180,3 +180,10 @@ db.posts.update({}, {
 		'_repost.user_id': '_repost.userId',
 	}
 }, false, true);
+
+db.signin.update({}, {
+	$rename: {
+		created_at: 'createdAt',
+		user_id: 'userId',
+	}
+}, false, true);