Running this module through the Coder module's check results in more than 400 warnings. Most are simple things like spacing,missing newlines and whatnot; however there are some errors in there that should be rectified in short order, namely "use quotes around a string literal array index, this is not only a style issue, but a known performance problem".

Example:

$table = $settings[civicrm_constant_contact_sync_group][table_name];

should be:

$table = $settings['civicrm_constant_contact_sync_group']['table_name'];
CommentFileSizeAuthor
#2 code_cleanup-1131046.patch36.28 KBchiddicks

Comments

bigjim’s picture

Thanks,

Any chance you can help out by submitting a patch?

chiddicks’s picture

StatusFileSize
new36.28 KB

Down to 65 errors by my count - patch based on this morning's latest 6.x-1.x dev version.

akakadak’s picture

Was this patch included in the 6.x-1.2 release on May 11, 2011?

bigjim’s picture

Status: Active » Closed (fixed)

I uploaded a commit that brings everything up to date with the "normal" coder standards, with the exception of the "global $civicrm_root" call with cannot meat the standards.