quick compatibility fixes and syntax cleanup