ServerEvents.commandRegistry(event => {
    const { commands: Commands } = event
    event.register(
        Commands.literal('clearec')
        .requires(src => src.hasPermission(2))
        .executes(ctx => {
            const server = ctx.source.server
            server.players.forEach(player => {
                player.enderChestInventory.clear()
            })
            return 1
        })
    )
})