Setup Circle CI, add brakeman config (#13)

* Add circle ci config

* Change config to fix tests

* Update config

* Fix eslint command, add brakeman
This commit is contained in:
Pranav Raj S
2019-08-21 12:59:56 +05:30
committed by GitHub
parent 6e4fec2b55
commit 2c144d5ad3
39 changed files with 847 additions and 616 deletions
+8 -11
View File
@@ -1,31 +1,28 @@
/* eslint no-console: 0 */
/* global axios */
/* global moment */
/* eslint no-undef: "error" */
/* eslint no-unused-expressions: ["error", { "allowShortCircuit": true }] */
export default {
methods: {
lastMessage(m) {
return m.messages.last();
},
unreadMessagesCount(m) {
return m.messages.filter(chat =>
chat.created_at * 1000 > m.agent_last_seen_at * 1000 &&
(chat.message_type === 0 && chat.private !== true)
return m.messages.filter(
chat =>
chat.created_at * 1000 > m.agent_last_seen_at * 1000 &&
(chat.message_type === 0 && chat.private !== true)
).length;
},
readMessages(m) {
return m.messages.filter(chat =>
chat.created_at * 1000 <= m.agent_last_seen_at * 1000
return m.messages.filter(
chat => chat.created_at * 1000 <= m.agent_last_seen_at * 1000
);
},
unReadMessages(m) {
return m.messages.filter(chat =>
chat.created_at * 1000 > m.agent_last_seen_at * 1000
return m.messages.filter(
chat => chat.created_at * 1000 > m.agent_last_seen_at * 1000
);
},
},
};