made the key splitting work properly