You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Your DummyLogger class seems to be implementing the LoggerInterface correctly, but the error you're encountering indicates a compatibility issue.
In PHP, when implementing an interface method, the parameter types and their order must match exactly. The error suggests that the emergency method in DummyLogger is not compatible with the one defined in LoggerInterface.
To resolve this, make sure the emergency method in your DummyLogger class exactly matches the method signature in LoggerInterface. The LoggerInterface method signature for emergency is:
public function emergency($message, array $context = []);
So, update your DummyLogger class accordingly:
public function emergency($message, array $context = []): void
{
// Your implementation here
}
The text was updated successfully, but these errors were encountered:
Your DummyLogger class seems to be implementing the LoggerInterface correctly, but the error you're encountering indicates a compatibility issue.
In PHP, when implementing an interface method, the parameter types and their order must match exactly. The error suggests that the emergency method in DummyLogger is not compatible with the one defined in LoggerInterface.
To resolve this, make sure the emergency method in your DummyLogger class exactly matches the method signature in LoggerInterface. The LoggerInterface method signature for emergency is:
public function emergency($message, array $context = []);
So, update your DummyLogger class accordingly:
public function emergency($message, array $context = []): void
{
// Your implementation here
}
The text was updated successfully, but these errors were encountered: