modified to eliminate dependency on Proper