PortalKit: fix bug that sometimes the portal related war files cannot be deleted well