CRM-12639-improvements : code improvements which also fixes the failing tests https://test.civicrm.org/job/CiviCRM-master-git/LABEL=debian6,SUITE=api_v3_AllTests/397/
Merge pull request #1312 from pratik-joshi/CRM-12639-improvements

CRM-12639-improvements : code improvements which also fixes the failing tests https://test.civicrm.org/job/CiviCRM-master-git/LABEL=debian6,SUITE=api_v3_AllTests/397/