Skip to content

Conversation

@atm-lucasmantegari
Copy link
Contributor

FIX - Correction of new hook PR

This PR corrects the PR for adding a new hook. I made the mistake of setting the text_info replacement to $reshook == 0, which is the default value for reshook, which always replaced the given with empty when the hook was not in use.

if ($reshook == 1) {
// for add information
$text_info .= $hookmanager->resPrint;
} elseif ($reshook == 0) {
Copy link
Member

@eldy eldy Oct 16, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i made an error by validating a new hook into an already released branch. i revert it.
You can submit the hook into develop branch.
Also the fix is not correct. We should have


if ($reshook == 1) {   // We replace
						// for add information
						$text_info = $hookmanager->resPrint;
} elseif ($reshook == 0) {     // default action, we add if there is something to add
						$text_info .= $hookmanager->resPrint;

@eldy eldy added the PR to fix - See feedback in comments PR needs to be fixed to be integrated (some comments should describes the fix to do) label Oct 16, 2024
@eldy
Copy link
Member

eldy commented Jan 15, 2025

It seems this PR was set with "Discussion" or "PR to fix" tag, but no answer nor correction was provided since a long time. So request is automatically closed.
Please reopened and add a comment if you think this is an error.

@eldy eldy closed this Jan 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

PR to fix - See feedback in comments PR needs to be fixed to be integrated (some comments should describes the fix to do)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants