changed middleware handling

Signed-off-by: Dominic Böttger <Dominic.Boettger@inspirationlabs.com>
version

[ci skip]