fix for ruby < 2