Cube moves when another cube is scaled

I have this “main” cube what you can scale with these scalers, but my problem is that there is another cube attached to it.
When i scale the main cube the secondary cube doesn’t move with it. So is there any possibility to make the secondary cube reactive with the scaling so it moves with it in X axis?

Screenshot 2023-11-16 134251
Screenshot 2023-11-14 104127

I hope this thread can help you.