mirror of
https://github.com/hcengineering/platform.git
synced 2024-11-22 21:50:34 +03:00
Fix space security (#6428)
Signed-off-by: Denis Bykhov <bykhov.denis@gmail.com>
This commit is contained in:
parent
946d84522c
commit
2273d99406
@ -249,7 +249,7 @@ export class SpaceSecurityMiddleware extends BaseMiddleware implements Middlewar
|
||||
params: null
|
||||
}
|
||||
ctx.derived.txes.push(tx)
|
||||
ctx.derived.targets.security = (it) => {
|
||||
ctx.derived.targets['security' + tx._id] = (it) => {
|
||||
// TODO: I'm not sure it is called
|
||||
if (it._id === tx._id) {
|
||||
return targets
|
||||
@ -383,7 +383,9 @@ export class SpaceSecurityMiddleware extends BaseMiddleware implements Middlewar
|
||||
await this.processTx(ctx, tx)
|
||||
const res = await this.provideTx(ctx, tx)
|
||||
for (const txd of ctx.derived.txes) {
|
||||
await this.processTx(ctx, txd)
|
||||
if (txd._id !== tx._id) {
|
||||
await this.processTx(ctx, txd)
|
||||
}
|
||||
}
|
||||
return res
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user