restruture application