Mentioning people whose handles include valid markdown would not survive
markdown to bbcode conversion wihout being mangled. An example that
brought this to my attention was a handle similar to this:
_someuser_@testsite.example
The underscores would be interpreted as emphasis in markdown, and
converted to:
[i]someuser[/i]@testsite.example
This patch should fix this, and hopefully any other issue with mentions
being mangled.
Introduce helper functions to access the various fields of the xchan
stored in `App::$observer'. This removes direct access to the attribute
from core, with the aim of allowing further refactoring later.
We can not yet make the `App::$observer` attribute private, though, as
it is also accessed directly by some addons.
The PHP Epub Meta library has a dependency that prevents deployment on
32bit architectures. We also don't need all the functionality in that
library, so this patch replaces it with our own simplified code for
fetching the cover embedded in Epub archives.
We also expand the test suite and clean up some minor issues in the
Epubthumbnail class.
If the /owa endpoint received a request with a missing or invalid
Authorization header, it would return an error to the requester, but
without any message describing why it failes.
This patch adds a message to the error response, so that it will be a
bit easier to debug these issues in the future.
The owa spec includes a 'message' field in the error response, but makes
it optional. Any conforming implementations should accept a response
that includes the 'message' field.
MySQL does not support the INSERT...RETURNING clause, while MariaDB
does. This patch ensures that the test is not skipped on MariaDB, but
only on an actual MySQL system.
A common use case is to insert a record into a database table, but also
instantiate an object from the inserted data. This requires that we know
the value of any default or calculated columns that is filled in by the
database when the row is inserter.
This patch adds a `insert` method to pda_dbo that will insert a row, and
immediately fetch the row back from the database – including the default
and calculated values not specified by the insert itself.