ticgal / mfa

MFA for GLPI
GNU Affero General Public License v3.0
2 stars 3 forks source link

put a sleep in code to getPendings from GLPI can list the queue #9

Closed fgendorf closed 9 months ago

fgendorf commented 10 months ago

Because the inside function on GLPI getPendings use just < on filter, the notification just created, less than 1 second is not available yet. Put a sleep(1); before call QueuedNotification::forceSendFor is enough to send the OTP immediately.

If the GLPI team adjust the filter in getPendings to <= this PR is not necessary

fgendorf commented 9 months ago

The GLPI project accept my PR to change the filter of getPendings from '<' to '<=' Next release this PR on MFA became useless

https://github.com/glpi-project/glpi/pull/16173

OscarBeiro commented 9 months ago

So, is it safe to ignore it for GLPI 10.0.11?

O mér., 13 de dec. de 2023, 19:20, Frederico Gendorf < @.***> escribiu:

The GLPI project accept my PR to change the filter of getPendings from '<' to '<=' Next release this PR on MFA became useless

— Reply to this email directly, view it on GitHub https://github.com/ticgal/mfa/pull/9#issuecomment-1854487757, or unsubscribe https://github.com/notifications/unsubscribe-auth/AEMLHEQP2VSGFRDHVY5H2N3YJHWVLAVCNFSM6AAAAABABROWN6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNJUGQ4DONZVG4 . You are receiving this because you are subscribed to this thread.Message ID: @.***>

--

TICGAL  / Eduardo Pondal 31 At. / 36003 / Pontevedra / Galiza / Spain / +34 986 10 1000 / Web https://tic.gal/ https://tic.gal/Helpdesk https://xes.ticgal.comFollow us on Linkedin https://streaklinks.com/BOkFTSucHF_p7EdZHg6Ax39U/https%3A%2F%2Fwww.linkedin.com%2Fcompany%2Fticgal%2F / Twitter https://streaklinks.com/BOkFTSmOzi9_tajKhwfLVSL6/https%3A%2F%2Ftwitter.com%2Fticgalcom / Facebook https://streaklinks.com/BOkFTSqmpiqG4jPXlAmJA-ta/https%3A%2F%2Fwww.facebook.com%2FTICgal / Instagram https://streaklinks.com/BOkFTSmLS1R7fAZSswd4hqIF/https%3A%2F%2Finstagram.com%2Fticgalcom

fgendorf commented 9 months ago

Accepted, but not merged yet... maybe on 10.0.12...