Both. The writers wrote it, and Bay approved and directed it.
OIC....
so yeah, my point was that even with a different director, the movie would still have plot holes/flaws if the story was poorly written to begin with....
I'm not an MBay fan, but at least i know now that it wasnt completely his fault...