Added filter on valid code