Added filter method for logger middleware