Actually there would be 3 or more nails in that 2x4 block so it stays firmly attached its whole length to the side board.
I found a pic of a bed that isn't filled with soil yet... it shows how the corners fit together, the nails clinched over, etc.
Hope this helps.
Shoe (off to cook sumpin' on the grill! It's been summertime here today!)