Thanks for this module.

I am not an expert, but i notice some possible optimisation.

In shadowbox.install :

1) shadowbox_requirements() line 52 & 41: there is a small logic issue. The switch case is limited to the runtime phase. In that case, it will always evaluate to REQUIREMENT_ERROR;

2) shadowbox_requirements() line 56: since we are in the case "runtime", i think this condition is not necessary: elseif ($phase == 'runtime')

Patch to follow

Comments

jibus’s picture

StatusFileSize
new1.57 KB
manfer’s picture

StatusFileSize
new3.45 KB

Some more changes to better match drupal coding standards and a no needed intermediate variable has been dropped.

jibus’s picture

Status: Needs review » Patch (to be ported)

Sounds good to me !

manfer’s picture

Status: Patch (to be ported) » Fixed

pushed to 7.x-4.x, 7.x-3.x and 6.x-4.x branches

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

  • Commit c90f04a on 7.x-4.x, 8.x-1.x by manfer:
    Issue #1955440 by Jibus, manfer: code optimization