Problem/Motivation
If you see the first lines of the Schema::dropField() method you will see that if there is not field no exception is thrown.
if (!$this->fieldExists($table, $field)) {
return FALSE;
}
Proposed resolution
Throw an exception like in the Schema::addField() method
if (!$this->tableExists($table)) {
throw new SchemaObjectDoesNotExistException(t("Cannot add field @table.@field: table doesn't exist.", ['@field' => $field, '@table' => $table]));
}
But with the correct message.
Remaining tasks
Test the patch.
User interface changes
None.
API changes
Update the doc with the throw exception info.
Data model changes
None.