Hi guys,

It seems suggest_duplicate_title has an administration configuration page that is defined in suggest_duplicate_title_menu, in suggest_duplicate_title.module, line 20 with the path admin/settings/suggest_title, which calls back the form suggest_duplicate_title_admin_settings in suggest_duplicate_title.module, line 34.

I think it would be recommended to move all the administration code in a separate file, called suggest_duplicate_title.admin.inc, different from the module file (which loads on every page), which would slightly lower the memory footprint of the module.

Feel free to let me know if you would have any questions, comments or concerns on any aspects of the discussed implementations, I would be glad to explain in more details.
Thanks very much to all, in advance, for your comments, feedback, and insight.
Cheers!

Comments

ycshen’s picture

Assigned: Unassigned » ycshen

I will take the issue.
Changing assignment to: ycshen.

ycshen’s picture

Status: Active » Needs review
StatusFileSize
new5.18 KB

Quick follow-up on this issue.

Please find attached to this ticket a patch against suggest_duplicate_title-6.x-1.x,it should resolve this issue described in the summary:
suggest_duplicate_title-move-admin-form-inc-file-1931750.patch

I didn't do any other change but to declare the file callback for the form page with 'file' => 'suggest_duplicate_title.admin.inc',, and then simply copy/pasted all the code related with the form and other functions used to a new file called suggest_duplicate_title.admin.inc.

This change doesn't add any new feature or function to the module, however, it improves its code organization, readability, maintainability as well as its memory footprint.

Please let me know if you would have any questions, objections, comments, suggestions, recommendations or concerns on the patch file or any aspects discussed in this ticket, I would be glad to provide more information, explain in more details or re-roll the patch if necessary.

Any questions, feedback, testing, changes, recommendations would be highly appreciated.
Thanks to all in advance.

tanzeel’s picture

Status: Needs review » Closed (fixed)

Thank you ycshen for the patch. I have granted authorization of that commit.

Cheers,
Tanzeel