Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions phalcon/Events/Manager.zep
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,6 @@ use SplPriorityQueue;
*/
class Manager implements ManagerInterface
{
const DEFAULT_PRIORITY = 100;

/**
* @var bool
*/
Expand Down
3 changes: 2 additions & 1 deletion phalcon/Events/ManagerInterface.zep
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,13 @@ namespace Phalcon\Events;
*/
interface ManagerInterface
{
const DEFAULT_PRIORITY = 100;
/**
* Attach a listener to the events manager
*
* @param object|callable handler
*/
public function attach(string! eventType, handler) -> void;
public function attach(string! eventType, handler, int! priority = self::DEFAULT_PRIORITY) -> void;

/**
* Detach the listener from the events manager
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
<?php
<?php // phpcs:disable PSR1.Classes.ClassDeclaration.MissingNamespace

// @codingStandardsIgnoreStart
use Phalcon\Mvc\Controller;

// @codingStandardsIgnoreSEnd

/**
* \DispatcherTestDefaultNoNamespaceController
* Dispatcher Controller for testing different dispatch scenarios
Expand All @@ -23,8 +20,8 @@
*/
class DispatcherTestDefaultNoNamespaceController extends Controller
{
const RETURN_VALUE_STRING = 'string';
const RETURN_VALUE_INT = 5;
public const RETURN_VALUE_STRING = 'string';
public const RETURN_VALUE_INT = 5;

public function beforeExecuteRoute()
{
Expand Down
Loading