Tighten up the code