Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Two improvments to libraries.module:
1- install_profile variable default value in D7 is standard not default
2- Replacing the long costly way to look for dirs. It's better than the old one, so thought of sharing it, feedback?
Comment | File | Size | Author |
---|---|---|---|
#2 | wrong-default-profile.patch | 1005 bytes | tstoeckler |
#1 | 995988-2.patch | 1.91 KB | good_man |
improvements.patch | 1.91 KB | good_man | |
Comments
Comment #1
good_man CreditAttribution: good_man commentedmissing to omit the trailing slash in the previous patch.
Comment #2
tstoecklerFirst of all: thanks very much for the effort.
The variable default is actually correct. The other part I'll have to look into more deeply.
Attached is a patch for the defaults thing. I will commit that in a minute.
Comment #3
tstoecklerhttp://drupal.org/cvs?commit=464996
Marking needs work for the other change.
@good_man: Please note that your patch does not abide by the coding standards. Pure code-style review follows:
Renaming $nomask to $exclude is unnecessary.
Renaming $dir to $search is unnecessary.
Comment has trailing whitespace. Also it doesn't make much sense to put in a comment referencing code that *used to be there*.
Don't use tabs. Use spaces instead.
Regarding the actual code:
I hadn't heard of glob() yet, but while the PHP Documentation generally makes it look like it would be better than open_dir() / close_dir(), what makes me wonder is that this code is basically a direct copy of Drupal 7's file_scan_directory() (http://api.drupal.org/api/drupal/includes--file.inc/function/file_scan_d...), and I cannot imagine that the team of core devs would neglect to use this function for no reason.
Powered by Dreditor.
Comment #4
tstoecklerWell, just searching on drupal.org for "glob()" (http://drupal.org/search/apachesolr_multisitesearch/glob%28%29), reveals that the following two lines from the PHP documentation make this a no-go for us:
Thus, marking fixed, because this issue actually had a commit.
Comment #5
sunyup, if glob() would be an option, then Drupal core would use it already.
Comment #6
good_man CreditAttribution: good_man commentedI thought it's because it's some how a hidden function, that's why they maybe didn't notice that. Anyhow, I really don't know what's going on with the tabs issue on my kate editor! will have to take a second look at it's config. Re. variables renaming, I think it's not neccessary now as we are ignoring the whole new section.
Thanks guys, appreciate your time!