Fixed more to work with 2.7