diff --git a/srcs/push_swap.c b/srcs/push_swap.c index a328fb3..2207196 100644 --- a/srcs/push_swap.c +++ b/srcs/push_swap.c @@ -38,10 +38,10 @@ int check_valid(t_stack *list) { if (!list) return (0); - if (is_ordered(list) == 1) - return (0); if (has_doubles(list) == 1) ps_stop(NULL, (t_list *)list, 3); + if (is_ordered(list) == 1) + return (0); return (1); }