Refactor checkCustomerIsActive