stop player from flying with the Elytra

quick question: Is there a way to make a player unable to use the elytra under ceratin condition? I only know of the player nbt FallFlying, but player data can sadly not be changed with datapacks.
Continue to help post