Mr. miku86, really thank you very much.
At the beginning when I saw your answer I did not believe that the error was that simple.
I mean, after spending several hours I lost objectivity, I came to think that the only possible option was an error in the script and everything was really fine, what a surprise.
I lost objectivity, sometimes you need to take a break and another point of view
Sincerely thank you very much! that solved everything.