Job: Fix typo in exception message for invalid specification
authorMáté Szabó <mszabo@wikia-inc.com>
Sun, 26 May 2019 12:22:45 +0000 (14:22 +0200)
committerMáté Szabó <mszabo@wikia-inc.com>
Sun, 26 May 2019 12:22:45 +0000 (14:22 +0200)
The Job::factory method throws an InvalidArgumentException if a given
job specification is invalid. The error message for this exception was
worded in correctly. This patch improves the message to avoid confusion.

Change-Id: I6cab739263c1d3530c0650823db022dd5a4b60bc

includes/jobqueue/Job.php

index d2f1dbc..2f98d53 100644 (file)
@@ -103,7 +103,9 @@ abstract class Job implements RunnableJob {
 
                                return $job;
                        } else {
-                               throw new InvalidArgumentException( "Could instantiate job '$command': bad spec!" );
+                               throw new InvalidArgumentException(
+                                       "Could not instantiate job '$command': bad spec!"
+                               );
                        }
                }