more pg fixes