#✅ emitInit params question

6 messages · Page 1 of 1 (latest)

pine pelican
#

Hello, sorry for asking this. Why on the emitInit the directus just only pass program as parameter? I want to access like database and itemsService from there. Is it possible? Thank you

await emitter.emitInit('cli.before', { program });

honest lakeBOT
#

Thanks for posting! This is a community powered server, so you may or may not get an answer based on available help and expertise. To increase your chances of somebody being able to help you, please help us help you making sure you:

  • Adding an explanation of exactly what you're trying to achieve.
  • Adding any and all related code or previous attempts.
  • Describing the exact issue or error you are facing.
  • Posting any screenshots if applicable.
  • Reading through https://stackoverflow.com/help/how-to-ask.

When you're done with this thread, please close it. Thanks! ✨

(If you have a support agreement and need help, please contact the core team via email.)

fading oyster
#

Those are passed to you in the hook context not in the individual event meta's

pine pelican
#

oh my bad, I forgot it. Thank you. Solved

honest lakeBOT
#

✅ emitInit params question