Zend Framework

ContextSwitch constructor has a parameter for helper configuration; no parameters should be specified

Details

  • Type: Bug Bug
  • Status: Resolved Resolved
  • Priority: Trivial Trivial
  • Resolution: Fixed
  • Affects Version/s: 1.5.0
  • Fix Version/s: 1.5.3
  • Component/s: Zend_Controller
  • Labels:
    None
  • Fix Version Priority:
    Should Have

Description

Zend_Controller_Action_Helper_ContextSwitch class constructor takes one parameter; as the helper broker doesn't allow for constructor parameters when it instantiates helpers, it should be removed. The parameter is not used in the method body.

Activity

Hide
Wil Sinclair added a comment -

Please categorize/fix as needed.

Show
Wil Sinclair added a comment - Please categorize/fix as needed.
Hide
Steven Reed added a comment -

A small clarification: If you wished to instantiate the ContextSwitch helper and pass it to the helper broker manually, you could of course specify a parameter to its constructor for configuration. Either setOptions() or setConfig() should be called if the parameter is not null.

Show
Steven Reed added a comment - A small clarification: If you wished to instantiate the ContextSwitch helper and pass it to the helper broker manually, you could of course specify a parameter to its constructor for configuration. Either setOptions() or setConfig() should be called if the parameter is not null.
Hide
Matthew Weier O'Phinney added a comment -

You can instantiate the helper manually and pass it to the helper broker; allowing for options in the constructor simply simplifies this to a single step.

Not an issue.

Show
Matthew Weier O'Phinney added a comment - You can instantiate the helper manually and pass it to the helper broker; allowing for options in the constructor simply simplifies this to a single step. Not an issue.
Hide
Steven Reed added a comment -

An issue still exists however where by the constructor parameter $options is not used in the constructor body. If it is not null it should be passed to either setOptions() or setConfig().

Show
Steven Reed added a comment - An issue still exists however where by the constructor parameter $options is not used in the constructor body. If it is not null it should be passed to either setOptions() or setConfig().
Hide
Matthew Weier O'Phinney added a comment -

Re-opening due to user feedback.

Show
Matthew Weier O'Phinney added a comment - Re-opening due to user feedback.
Hide
Matthew Weier O'Phinney added a comment -

Scheduling for next mini release.

Show
Matthew Weier O'Phinney added a comment - Scheduling for next mini release.
Hide
Matthew Weier O'Phinney added a comment -

Fixed in trunk and 1.5 and 1.6 release branches

Show
Matthew Weier O'Phinney added a comment - Fixed in trunk and 1.5 and 1.6 release branches

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved:

Time Tracking

Estimated:
15m
Original Estimate - 15 minutes
Remaining:
15m
Remaining Estimate - 15 minutes
Logged:
Not Specified
Time Spent - Not Specified