Skip to content

Send and receive SMS messages using your Android phone programmatically via a simple HTTP API

Fix lint errors

Acho Arnold73d5b50d5003
diff --git a/web/store/index.ts b/web/store/index.ts
index a1ffc377..0bf0cef4 100644
--- a/web/store/index.ts
+++ b/web/store/index.ts
@@ -360,7 +360,7 @@ export const actions = {
fcm_token: phone.fcm_token,
phone_number: phone.phone_number,
message_expiration_seconds: parseInt(
- phone.message_expiration_seconds.toString(),
+ phone.message_expiration_seconds.toString()
),
max_send_attempts: parseInt(phone.max_send_attempts.toString()),
messages_per_minute: parseInt(phone.messages_per_minute.toString()),
@@ -380,7 +380,7 @@ export const actions = {
async handleAxiosError(
context: ActionContext<State, State>,
- error: AxiosError,
+ error: AxiosError
) {
const errorMessage =
error.response?.data?.data[Object.keys(error.response?.data?.data)[0]][0]
@@ -415,7 +415,7 @@ export const actions = {
async sendMessage(
context: ActionContext<State, State>,
- request: SendMessageRequest,
+ request: SendMessageRequest
) {
await axios.post('/v1/messages/send', request)
await Promise.all([
@@ -430,7 +430,7 @@ export const actions = {
addNotification(
context: ActionContext<State, State>,
- request: NotificationRequest,
+ request: NotificationRequest
) {
context.commit('setNotification', request)
},
@@ -445,7 +445,7 @@ export const actions = {
async loadThreadMessages(
context: ActionContext<State, State>,
- threadId: string | null,
+ threadId: string | null
) {
await context.commit('setThreadId', threadId)
const response = await axios.get('/v1/messages', {
@@ -460,7 +460,7 @@ export const actions = {
async setAuthUser(
context: ActionContext<State, State>,
- user: AuthUser | null | undefined,
+ user: AuthUser | null | undefined
) {
const userChanged = user?.id !== context.getters.getAuthUser?.id
@@ -477,7 +477,7 @@ export const actions = {
])
const phone = context.getters.getPhones.find(
- (x: Phone) => x.id === context.getters.getUser.active_phone_id,
+ (x: Phone) => x.id === context.getters.getUser.active_phone_id
)
if (phone) {
await context.dispatch('setOwner', phone.phone_number)
@@ -487,7 +487,7 @@ export const actions = {
async onAuthStateChanged(
context: ActionContext<State, State>,
// @ts-ignore
- { authUser },
+ { authUser }
) {
if (authUser == null) {
context.commit('setAuthUser', null)
@@ -520,7 +520,7 @@ export const actions = {
async updateThread(
context: ActionContext<State, State>,
- payload: { threadId: string; isArchived: boolean },
+ payload: { threadId: string; isArchived: boolean }
) {
await axios.put(`/v1/message-threads/${payload.threadId}`, {
is_archived: payload.isArchived,
@@ -573,7 +573,7 @@ export const actions = {
createWebhook(
context: ActionContext<State, State>,
- payload: RequestsWebhookStore,
+ payload: RequestsWebhookStore
) {
return new Promise<EntitiesWebhook>((resolve, reject) => {
axios
@@ -621,7 +621,7 @@ export const actions = {
updateWebhook(
context: ActionContext<State, State>,
- payload: RequestsWebhookUpdate & { id: string },
+ payload: RequestsWebhookUpdate & { id: string }
) {
return new Promise<EntitiesWebhook>((resolve, reject) => {
axios