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

Move functions to Utility class #28

Open
mambax7 opened this issue May 27, 2020 · 1 comment
Open

Move functions to Utility class #28

mambax7 opened this issue May 27, 2020 · 1 comment
Labels
enhancement New feature or request

Comments

@mambax7
Copy link

mambax7 commented May 27, 2020

We should move the standard functions from /class/Utility.php to /class/Common/SysUtility.php, like what we have in Suico:
https://github.com/XoopsModules25x/suico/blob/master/class/Common/SysUtility.php

Then make the Utility class inherit from SysUtility:

class Utility extends Common\SysUtility

as here: https://github.com/XoopsModules25x/suico/blob/master/class/Utility.php

and then move all the module specific functions from /include/functions.php to the Utility class, while making them all "static"

This way we'll remove them from the Global space

@mambax7 mambax7 added the enhancement New feature or request label May 27, 2020
@ggoffy
Copy link
Collaborator

ggoffy commented May 27, 2020

can you please create a directory on github (e.g. under https://github.com/XoopsModules25x) for all these common files
then I can always implement the last version, or fork it to contribute,...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants