Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
timothe
duniter
Commits
a260d458
Commit
a260d458
authored
May 28, 2019
by
Cédric Moreau
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[fix] #1379: missing code
parent
d813d34d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletion
+4
-1
app/service/IdentityService.ts
app/service/IdentityService.ts
+4
-1
No files found.
app/service/IdentityService.ts
View file @
a260d458
...
...
@@ -227,13 +227,16 @@ export class IdentityService extends FIFOService {
written_hash
:
null
,
block
:
cert
.
block_number
}
if
(
current
&&
mCert
.
expires_on
<
current
.
medianTime
)
{
throw
DataErrors
[
DataErrors
.
CERT_WINDOW_IS_PASSED
]
}
let
existingCert
=
await
this
.
dal
.
existsCert
(
mCert
,
current
)
if
(
!
existingCert
)
{
if
(
!
(
await
this
.
dal
.
certDAL
.
getSandboxForKey
(
cert
.
from
).
acceptNewSandBoxEntry
(
mCert
,
this
.
conf
.
pair
&&
this
.
conf
.
pair
.
pub
)))
{
throw
constants
.
ERRORS
.
SANDBOX_FOR_CERT_IS_FULL
;
}
await
this
.
dal
.
registerNewCertification
(
mCert
)
this
.
logger
.
info
(
'
✔ CERT %s
'
,
mC
ert
.
from
)
;
this
.
logger
.
info
(
'
✔ CERT
%s block#%s ->
%s
'
,
c
ert
.
from
,
cert
.
block_number
,
idty
.
uid
)
}
else
{
throw
constants
.
ERRORS
.
ALREADY_UP_TO_DATE
;
}
...
...
Write
Preview
Markdown
is supported
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