Fix #29

corrected check for delegate method