fix allocation and make homepage