wiki.techinc.nl/includes/utils
Timo Tijhof b862174dc0 UrlUtils: Make assemble() and removeDotSegments() stateless
Follows-up 472a914c63 (I706ef8a50aafb51), which moved various
functions here en-mass, but these two don't require any state.

The warnings about parse_url() in UrlUtils.php have been obsolete
since about PHP 5.4, when it started to support protocol-relative
URLs, non-slash protocols like "mailto", and deal with spaces/newlines
correctly (https://3v4l.org/YWUkl).

Rather than complicate many components that would otherwise remain
stateless and unit-testable, fix these to once again be the static
functions they were.

For impact, see upto PS17 of change I5117eab95f57297eb02bed.

Bug: T227900
Change-Id: Ifb3f720fc429b107348644c98eb9cd8e1113a42a
2023-08-10 03:39:42 +01:00
..
AutoloadGenerator.php Merge "utils: Use str_starts_with/str_ends_with/str_contains" 2022-11-11 10:41:04 +00:00
BatchRowIterator.php Use more narrow IReadableDatabase in BatchRowIterator 2023-05-19 15:02:50 +02:00
BatchRowUpdate.php
BatchRowWriter.php Migrate more usages of Database::update() to UpdateQueryBuilder 2023-06-09 13:36:04 +00:00
ClassCollector.php Miscellaneous PHP version related cleanups 2022-11-21 10:11:53 +11:00
ExecutableFinder.php utils: Use str_starts_with/str_ends_with/str_contains 2022-10-04 23:09:44 +02:00
FileContentsHasher.php
MWCryptHKDF.php
MWCryptRand.php
MWFileProps.php Use short array destructuring instead of list() 2022-10-21 15:33:37 +11:00
MWRestrictions.php Revert "Reorg: Move some of request related classes to MediaWiki/Request" 2022-10-27 13:14:16 +00:00
README
RowUpdateGenerator.php
UIDGenerator.php
UrlUtils.php UrlUtils: Make assemble() and removeDotSegments() stateless 2023-08-10 03:39:42 +01:00
ZipDirectoryReader.php Replace some more usages of deprecated MWException 2023-06-09 02:07:08 +02:00
ZipDirectoryReaderError.php

The classes in this directory are general utilities for use by any part of
MediaWiki. They do not favour any particular user interface and are not
constrained to serve any particular feature. This is similar to includes/libs,
except that some dependency on the MediaWiki framework (such as the use of
MWException, Status or wfDebug()) disqualifies them from use outside of
MediaWiki without modification.

Utilities should not use global configuration variables, rather they should rely
on the caller to configure their behaviour.