Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Hiro
GetTor
Commits
e9ee80b1
Commit
e9ee80b1
authored
Oct 16, 2019
by
Hiro
🏄
Browse files
Fix bug in email parser
parent
815e4571
Changes
1
Hide whitespace changes
Inline
Side-by-side
gettor/parse/email.py
View file @
e9ee80b1
...
...
@@ -199,11 +199,7 @@ class EmailParser(object):
def
check_num_requests
(
self
,
request_id
,
request_service
,
limit
):
now_str
=
datetime
.
now
().
strftime
(
"%Y%m%d%H%M%S"
)
dbname
=
self
.
settings
.
get
(
"dbname"
)
conn
=
SQLite3
(
dbname
)
hid
=
hashlib
.
sha256
(
request
[
'id'
].
encode
(
'utf-8'
))
hid
=
hashlib
.
sha256
(
request_id
.
encode
(
'utf-8'
))
# check limits first
num_requests
=
limit
...
...
@@ -234,6 +230,9 @@ class EmailParser(object):
execution details.
"""
email_requests_limit
=
self
.
settings
.
get
(
"email_requests_limit"
)
now_str
=
datetime
.
now
().
strftime
(
"%Y%m%d%H%M%S"
)
dbname
=
self
.
settings
.
get
(
"dbname"
)
conn
=
SQLite3
(
dbname
)
if
request
[
"command"
]:
log
.
msg
(
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment