Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[4.4] Fix Sample data installation, fix finder helper addContentType null value #43052

Open
wants to merge 1 commit into
base: 4.4-dev
Choose a base branch
from

Conversation

Fedik
Copy link
Member

@Fedik Fedik commented Mar 16, 2024

Pull Request for Issue # .

Summary of Changes

Helper::addContentType() allows null for mime, however $db->quote() does not.
Same as #43051 but for 4.4

Testing Instructions

Use PHP 8+, set error reaporting to Maximum
On clean installation, try install "Blog Sample Data"

Run following code (example in index.php of the template):

$name = uniqid(); // Imitating a new content type name, can be any string
var_dump(Joomla\Component\Finder\Administrator\Indexer\Helper::addContentType($name));

Actual result BEFORE applying this Pull Request

PHP warning Deprecated: PDO::quote(): Passing null to parameter 1 ($string) of type string is deprecated

Expected result AFTER applying this Pull Request

No warning

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:
  • No documentation changes for docs.joomla.org needed
  • Pull Request link for manual.joomla.org:
  • No documentation changes for manual.joomla.org needed

@Fedik Fedik added PHP 8.x PHP 8.x deprecated issues bug labels Mar 16, 2024
@toivo
Copy link
Contributor

toivo commented Mar 19, 2024

I have tested this item 🔴 unsuccessfully on 1738f32

Unable to reproduce the error in out-of-the-box Joomla 4.4.4-dev, run in Wampserver 3.3.3 usin PHP 8.2.13 on Windows 11.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43052.

@Fedik
Copy link
Member Author

Fedik commented Mar 19, 2024

I have updated test instruction,
old one was more for 5.x.

@HLeithner HLeithner changed the title Fix Sample data installation, fix finder helper addContentType null value [4.4] Fix Sample data installation, fix finder helper addContentType null value Apr 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug PHP 8.x PHP 8.x deprecated issues PR-4.4-dev
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants