more work on CRM-12463, fixed api for backward compatibility
Merge pull request #636 from kurund/CRM-12463-fixes

more work on CRM-12463, fixed api for backward compatibility