Move callback code from proc into private method