mirror of
https://github.com/ProtonMail/proton-bridge.git
synced 2025-12-15 22:56:48 +00:00
GODT-1056 Check encrypted size of the message before upload
This commit is contained in:
@ -99,6 +99,11 @@ func (loop *eventLoop) setFirstEventID() (err error) {
|
||||
// pollNow starts polling events right away and waits till the events are
|
||||
// processed so we are sure updates are propagated to the database.
|
||||
func (loop *eventLoop) pollNow() {
|
||||
// When event loop is not running, it would cause infinite wait.
|
||||
if !loop.isRunning {
|
||||
return
|
||||
}
|
||||
|
||||
eventProcessedCh := make(chan struct{})
|
||||
loop.pollCh <- eventProcessedCh
|
||||
<-eventProcessedCh
|
||||
|
||||
Reference in New Issue
Block a user