File tree 1 file changed +3
-3
lines changed
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -41,7 +41,7 @@ getUf = () ->
41
41
parseDuration = (duration ) ->
42
42
return moment .utc (duration * 1000 ).format (" HH:mm:ss" )
43
43
44
- process = (timeEntries , amount , price ) ->
44
+ processTimeEntries = (timeEntries , amount , price ) ->
45
45
new Promise (resolve , reject ) ->
46
46
getUf ().then (uf) ->
47
47
limit = (amount / (uf * price)) * 3600
@@ -106,13 +106,13 @@ module.exports = (robot) ->
106
106
message = " "
107
107
toggl = getClient encryptor .decrypt user .toggl .api_token
108
108
toggl .getTimeEntriesAsync (start, end).then (timeEntries) ->
109
- process timeEntries, amount, price
109
+ processTimeEntries timeEntries, amount, price
110
110
.then (data) ->
111
111
message = data .message
112
112
toggl .updateTimeEntriesTagsAsync data .teIds , tags, action
113
113
.then () ->
114
114
res .send message
115
- welcome = " #{ msg .message .user .name } close tasks successfull"
115
+ welcome = " #{ res .message .user .name } close tasks successfull"
116
116
robot .messageRoom (channel, " #{ welcome} \n #{ message} " )
117
117
.catch (err) ->
118
118
res .reply " an error occurred in toggl"
You can’t perform that action at this time.
0 commit comments