fix bug no middleware