History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: OX-5328
Type: Bug Bug
Status: Verified Verified
Priority: Trivial Trivial
Assignee: Chris Nutting
Reporter: Heiko Weber
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
OpenX Ad Server

Missing class OX_ParserPlugin_Error handicap plugin development

Created: 28/Apr/09 08:15 AM   Updated: 28/Apr/09 04:32 PM
Component/s: OXP: Plugins
Affects Version/s: OpenX 2.8.0
Fix Version/s: None
Security Level: Public (All users can see these issues)

Time Tracking:
Original Estimate: 0.25h
Original Estimate - 0.25h
Remaining Estimate: 0.25h
Remaining Estimate - 0.25h
Time Spent: Not Specified
Remaining Estimate - 0.25h

File Attachments: 1. File ParserBase.php (11 kb)
2. File PluginManager.php (56 kb)



 Description  « Hide
If new plugins are installed within the UI "bad" plugin-code causes lib/OX/Plugin/ParserBase.php to throw a "'OX_ParserPlugin_Error'" (trunk: line #297), but class OX_ParserPlugin_Error is never defined - this makes it difficult to search the issue on plugin development. Adding something like:
class OX_ParserPlugin_Error extends PEAR_Error
{
    /**
     * OX_ParserPlugin_Error constructor.
     *
     * @param mixed     error code, or string with error message.
     * @param int       what 'error mode' to operate in
     * @param int       what error level to use for $mode & PEAR_ERROR_TRIGGER
     * @param mixed     additional debug info, such as the last query
     * @access  public
     */
    function OX_ParserPlugin_Error($code = 'OX_ParserPlugin_Error', $mode = PEAR_ERROR_RETURN,
              $level = E_USER_NOTICE, $debuginfo = null)
    {
        $this->PEAR_Error('OX_ParserPlugin_Error: ' . $code, $code, $mode, $level, $debuginfo);
    }
}

to lib/OX/Plugin/ParserPlugin.php display the error nicely within the UI.

Heiko



 All   Comments   Work Log   Change History   FishEye   Crucible   Builds      Sort Order: Ascending order - Click to sort in descending order
Change by Chris Nutting - 28/Apr/09 04:28 PM
Field Original Value New Value
Status Needs Verification [ 10000 ] Verified [ 10001 ]

Change by Chris Nutting - 28/Apr/09 04:29 PM
Attachment ParserBase.php [ 12006 ]

Change by Chris Nutting - 28/Apr/09 04:29 PM
Attachment PluginManager.php [ 12007 ]

Chris Nutting - 28/Apr/09 04:32 PM
Thanks!, This was brought up by a user in #openx (Chris Stephens) as well, he suggested the change I just attached.

Change by Chris Nutting - 28/Apr/09 04:32 PM
Assignee Andrew Hill [ andrew.hill ] Chris Nutting [ chris.nutting ]