fixed logic in active admin