Skip to content

Commit

Permalink
Merge pull request SimpleMachines#8185 from RainRat/release-3.0
Browse files Browse the repository at this point in the history
fix typos Signed-off-by: RainRat rainrat78@yahoo.ca
  • Loading branch information
Sesquipedalian committed Apr 26, 2024
2 parents 49b1ec4 + be921e8 commit bf6ad0f
Show file tree
Hide file tree
Showing 38 changed files with 52 additions and 52 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/standard_bug.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ body:
label: Database Version
description: |
Your database version
You mabe be able to runt he following query: `SELECT version();` to get this.
You may be able to run the following query: `SELECT version();` to get this.
placeholder: '8.0.1-MySQL'
- type: input
id: phpversion
Expand Down
2 changes: 1 addition & 1 deletion Sources/Actions/Admin/Languages.php
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@ public function download(): void
$context_data['version'] = $match[1];
}

// Now does the old file exist - if so what is it's version?
// Now does the old file exist - if so what is its version?
if (file_exists(Config::$boarddir . '/' . $file['filename'])) {
// OK - what is the current version?
$fp = fopen(Config::$boarddir . '/' . $file['filename'], 'rb');
Expand Down
2 changes: 1 addition & 1 deletion Sources/Actions/Admin/Maintenance.php
Original file line number Diff line number Diff line change
Expand Up @@ -1815,7 +1815,7 @@ public function massMove(): void
Utils::$context['continue_percent'] = round(100 * (Utils::$context['start'] / $total_topics), 1);
Utils::$context['continue_get_data'] = '?action=admin;area=maintain;sa=topics;activity=massmove;id_board_from=' . $id_board_from . ';id_board_to=' . $id_board_to . ';totaltopics=' . $total_topics . ';start=' . Utils::$context['start'] . ';' . Utils::$context['session_var'] . '=' . Utils::$context['session_id'];

// Let the template system do it's thang.
// Let the template system do its thang.
return;
}
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/Actions/Admin/Reports.php
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ public function boards(): void
}
Db::$db->free_result($request);

// Get every moderator gruop.
// Get every moderator group.
$moderator_groups = [];

$request = Db::$db->query(
Expand Down
2 changes: 1 addition & 1 deletion Sources/Actions/Credits.php
Original file line number Diff line number Diff line change
Expand Up @@ -391,7 +391,7 @@ public function execute(): void
Utils::$context['copyrights'] = [
'smf' => Lang::formatText(Lang::$forum_copyright, ['version' => SMF_FULL_VERSION, 'year' => SMF_SOFTWARE_YEAR, 'scripturl' => Config::$scripturl]),
/* Modification Authors: You may add a copyright statement to this array for your mods.
Copyright statements should be in the form of a value only without a array key. I.E.:
Copyright statements should be in the form of a value only without an array key. I.E.:
'Some Mod by Thantos © 2010',
Lang::$txt['some_mod_copyright'],
*/
Expand Down
2 changes: 1 addition & 1 deletion Sources/Actions/Moderation/Logs.php
Original file line number Diff line number Diff line change
Expand Up @@ -619,7 +619,7 @@ public static function list_getModLogEntries(int $start, int $items_per_page, st

// Do some formatting of the action string.
foreach ($entries as $k => $entry) {
// Make any message info links so its easier to go find that message.
// Make any message info links so it's easier to go find that message.
if (isset($entry['extra']['message']) && (empty($entry['message']) || empty($entry['message']['id']))) {
$entries[$k]['extra']['message'] = '<a href="' . Config::$scripturl . '?msg=' . $entry['extra']['message'] . '">' . $entry['extra']['message'] . '</a>';
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/Actions/Post2.php
Original file line number Diff line number Diff line change
Expand Up @@ -503,7 +503,7 @@ public function submit(): void
unset($_SESSION['already_attached']);
}

// If we had a draft for this, its time to remove it since it was just posted
// If we had a draft for this, it's time to remove it since it was just posted
if (!empty(Config::$modSettings['drafts_post_enabled']) && !empty($_POST['id_draft'])) {
Draft::delete((int) $_POST['id_draft']);
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/Actions/Profile/BuddyIgnoreLists.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
use SMF\Utils;

/**
* Show all the users buddies, as well as a add/delete interface.
* Show all the users buddies, as well as an add/delete interface.
*/
class BuddyIgnoreLists implements ActionInterface
{
Expand Down
2 changes: 1 addition & 1 deletion Sources/Actions/Register2.php
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ public function execute(): void
Utils::redirectexit('action=signup');
}

// If we require neither an agreement nor a privacy policy, we need a extra check for coppa.
// If we require neither an agreement nor a privacy policy, we need an extra check for coppa.
if (empty(Config::$modSettings['requireAgreement']) && empty(Config::$modSettings['requirePolicyAgreement']) && !empty(Config::$modSettings['coppaAge'])) {
$_SESSION['skip_coppa'] = !empty($_POST['accept_agreement']);
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/BBCodeParser.php
Original file line number Diff line number Diff line change
Expand Up @@ -2283,7 +2283,7 @@ public static function sanitizeMSCutPaste(string $string): string
* Backward compatibility wrapper for parse() and/or getCodes().
*
* @param string|bool $message The message.
* When a empty string, nothing is done.
* When an empty string, nothing is done.
* When false we provide a list of BBC codes available.
* When a string, the message is parsed and bbc handled.
* @param bool $smileys Whether to parse smileys as well.
Expand Down
2 changes: 1 addition & 1 deletion Sources/BrowserDetector.php
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,7 @@ private function setupIe(): void
if (preg_match('~Trident/([0-9.])~i', $_SERVER['HTTP_USER_AGENT'], $trident_match) === 1) {
$this->_browsers['is_ie' . ((int) $trident_match[1] + 4)] = true;

// If trident is set, see the (if any) msie tag in the user agent matches ... if not its in some compatibility view
// If trident is set, see the (if any) msie tag in the user agent matches ... if not it's in some compatibility view
if (isset($msie_match[1]) && ($msie_match[1] < $trident_match[1] + 4)) {
$this->_browsers['is_ie_compat_view'] = true;
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/Config.php
Original file line number Diff line number Diff line change
Expand Up @@ -2818,7 +2818,7 @@ public static function stripPhpComments(string $code_str): string
* If it fails, Settings.php will assume 0.
*
* @param int $time The timestamp of the last DB error
* @param bool True If we should update the current db_last_error context as well. This may be useful in cases where the current context needs to know a error was logged since the last check.
* @param bool True If we should update the current db_last_error context as well. This may be useful in cases where the current context needs to know an error was logged since the last check.
* @return bool True If we could successfully put the file or not.
*/
public static function updateDbLastError(int $time, bool $update = true): bool
Expand Down
2 changes: 1 addition & 1 deletion Sources/Db/APIs/MySQL.php
Original file line number Diff line number Diff line change
Expand Up @@ -2110,7 +2110,7 @@ protected function initiate(string $user, string $passwd, array $options = []):
);
}

// Something's wrong, show an error if its fatal (which we assume it is)
// Something's wrong, show an error if it's fatal (which we assume it is)
if ($success === false) {
if (!empty($options['non_fatal'])) {
$this->connection = null;
Expand Down
2 changes: 1 addition & 1 deletion Sources/Db/APIs/PostgreSQL.php
Original file line number Diff line number Diff line change
Expand Up @@ -2225,7 +2225,7 @@ function ($errno, $errstr) {
}
restore_error_handler();

// Something's wrong, show an error if its fatal (which we assume it is)
// Something's wrong, show an error if it's fatal (which we assume it is)
if (empty($this->connection) && empty($options['non_fatal'])) {
ErrorHandler::displayDbError();
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/Editor.php
Original file line number Diff line number Diff line change
Expand Up @@ -854,7 +854,7 @@ protected function setSCEditorOptions(): void
}

// Allow mods to change $this->sce_options.
// Usful if, e.g., a mod wants to add an SCEditor plugin.
// Useful if, e.g., a mod wants to add an SCEditor plugin.
IntegrationHook::call('integrate_sceditor_options', [&$this->sce_options]);
}
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/Event.php
Original file line number Diff line number Diff line change
Expand Up @@ -988,7 +988,7 @@ public static function get(string $low_date, string $high_date, bool $use_permis
}

/**
* Creates a event and saves it to the database.
* Creates an event and saves it to the database.
*
* Does not check permissions.
*
Expand Down
2 changes: 1 addition & 1 deletion Sources/ItemList.php
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ protected function checkOptions(array $options): bool
$have_what_we_need &= empty($options['items_per_page']) || (isset($options['get_count']['function'], $options['base_href']) && is_numeric($options['items_per_page']));
}

// @TODO: The var becomes a int because of &= usage.
// @TODO: The var becomes an int because of &= usage.
return (bool) $have_what_we_need;
}

Expand Down
2 changes: 1 addition & 1 deletion Sources/Lang.php
Original file line number Diff line number Diff line change
Expand Up @@ -790,7 +790,7 @@ public static function getLocaleFromLanguageName(string $lang): ?string
}

/**
* A backward compability method for loading language files with old names.
* A backward compatibility method for loading language files with old names.
* This is used to support backward compatibility with mods from SMF 2.1.
* Do not rely on this method to exist in future versions!
*
Expand Down
2 changes: 1 addition & 1 deletion Sources/Mail.php
Original file line number Diff line number Diff line change
Expand Up @@ -559,7 +559,7 @@ public static function reduceQueue(bool|int $number = false, bool $override_limi
['variable'],
);

// If we have failed to many times, tell mail to wait a bit and try again.
// If we have failed too many times, tell mail to wait a bit and try again.
if (Config::$modSettings['mail_failed_attempts'] > 5) {
Db::$db->query(
'',
Expand Down
2 changes: 1 addition & 1 deletion Sources/PackageManager/SubsPackage.php
Original file line number Diff line number Diff line change
Expand Up @@ -527,7 +527,7 @@ public static function loadInstalledPackages(): array
/**
* Loads a package's information and returns a representative array.
* - expects the file to be a package in Packages/.
* - returns a error string if the package-info is invalid.
* - returns an error string if the package-info is invalid.
* - otherwise returns a basic array of id, version, filename, and similar information.
* - an XmlArray is available in 'xml'.
*
Expand Down
2 changes: 1 addition & 1 deletion Sources/PackageManager/XmlArray.php
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ public function fetch(string $path, bool $get_elements = false): string|bool
*
* @param string $path The path to the element to get
* @param bool $return_full Whether to return the full result set
* @return XmlArray|string|bool a new XmlArray. False if we can not find a attribute
* @return XmlArray|string|bool a new XmlArray. False if we can not find an attribute
*/
public function path(string $path, bool $return_full = false): XmlArray|string|false
{
Expand Down
2 changes: 1 addition & 1 deletion Sources/PersonalMessage/DraftPM.php
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ public static function showInProfile(int $memID = -1): void
$recipient_ids = (!empty($row['to_list'])) ? Utils::jsonDecode($row['to_list'], true) : [];

// @todo ... this is a bit ugly since it runs an extra query for every message, do we want this?
// at least its only for draft PM's and only the user can see them ... so not heavily used .. still
// at least it's only for draft PM's and only the user can see them ... so not heavily used .. still
if (!empty($recipient_ids['to']) || !empty($recipient_ids['bcc'])) {
$recipient_ids['to'] = array_map('intval', $recipient_ids['to']);
$recipient_ids['bcc'] = array_map('intval', $recipient_ids['bcc']);
Expand Down
2 changes: 1 addition & 1 deletion Sources/PersonalMessage/PM.php
Original file line number Diff line number Diff line change
Expand Up @@ -1095,7 +1095,7 @@ public static function compose2(): bool
return false;
}

// If we had a PM draft for this one, then its time to remove it since it was just sent
// If we had a PM draft for this one, then it's time to remove it since it was just sent
if (Utils::$context['drafts_save'] && !empty($_POST['id_draft'])) {
DraftPM::delete($_POST['id_draft']);
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/Profile.php
Original file line number Diff line number Diff line change
Expand Up @@ -2713,7 +2713,7 @@ protected function setAvatarExternal(string $url): ?string
return $this->setAvatarAttachment($image->source);
}

// Is is safe?
// Is it safe?
if (!$image->check(!empty(Config::$modSettings['avatar_paranoid']))) {
return 'bad_avatar';
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/Punycode.php
Original file line number Diff line number Diff line change
Expand Up @@ -550,7 +550,7 @@ protected function preprocess(string $domain, array &$errors = []): string
*
* @param string $label Individual part of a domain name.
* @param bool $toPunycode True for encoding to Punycode, false for decoding.
* @return int 0 if valid, otherwise a int matching a defined const.
* @return int 0 if valid, otherwise an int matching a defined const.
*/
protected function validateLabel(string $label, bool $toPunycode = true): int
{
Expand Down
6 changes: 3 additions & 3 deletions Sources/Sapi.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
* the API call will do nothing.
*
* Some functions may not be defined or definable in the documentation as they are
* bundled by 3rd party processes, such as apache_* functions. To surpress IDE
* bundled by 3rd party processes, such as apache_* functions. To suppress IDE
* warnings, we use 'suppress PHP0417'.
*/
class Sapi
Expand Down Expand Up @@ -126,7 +126,7 @@ public static function isOS(string|array $os): bool
}

/**
* Checks If we are runnig a CGI instance.
* Checks If we are running a CGI instance.
*
* @return bool True if we are running under CGI, false otherwise.
*/
Expand All @@ -136,7 +136,7 @@ public static function isCGI(): bool
}

/**
* Checks If we are runnig a CLI (shell/cron) instance.
* Checks If we are running a CLI (shell/cron) instance.
*
* @return bool True if we are running under CLI, false otherwise.
*/
Expand Down
8 changes: 4 additions & 4 deletions Sources/Tasks/CreatePost_Notify.php
Original file line number Diff line number Diff line change
Expand Up @@ -569,7 +569,7 @@ protected function handleWatchedNotifications(): void
$parsed_message[$localization]['body'] = trim(Utils::htmlspecialcharsDecode(strip_tags(strtr($bbcparser->parse($parsed_message[$localization]['body'], false), ['<br>' => "\n", '</div>' => "\n", '</li>' => "\n", '&#91;' => '[', '&#93;' => ']', '&#39;' => '\'', '</tr>' => "\n", '</td>' => "\t", '<hr>' => "\n---------------------------------------------------------------\n"]))));
}

// Bitwise check: Receiving a alert?
// Bitwise check: Receiving an alert?
if ($pref & self::RECEIVE_NOTIFY_ALERT) {
$this->alert_rows[] = [
'alert_time' => time(),
Expand All @@ -590,7 +590,7 @@ protected function handleWatchedNotifications(): void
];
}

// Bitwise check: Receiving a email notification?
// Bitwise check: Receiving an email notification?
if ($pref & self::RECEIVE_NOTIFY_EMAIL) {
$itemID = $content_type == 'board' ? (int) $topicOptions['board'] : (int) $topicOptions['id'];

Expand Down Expand Up @@ -660,7 +660,7 @@ protected function handleQuoteNotifications(): void
];
}

// Bitwise check: Receiving a email notification?
// Bitwise check: Receiving an email notification?
if (!($pref & self::RECEIVE_NOTIFY_EMAIL)) {
// Don't want an email, so forget this member in any respawned tasks.
unset($msgOptions['quoted_members'][$member_id]);
Expand Down Expand Up @@ -729,7 +729,7 @@ protected function handleMentionedNotifications(): void
];
}

// Bitwise check: Receiving a email notification?
// Bitwise check: Receiving an email notification?
if (!($pref & self::RECEIVE_NOTIFY_EMAIL)) {
// Don't want an email, so forget this member in any respawned tasks.
unset($msgOptions['mentioned_members'][$member_id]);
Expand Down
6 changes: 3 additions & 3 deletions Sources/Theme.php
Original file line number Diff line number Diff line change
Expand Up @@ -433,7 +433,7 @@ public static function loadSubTemplate(string $sub_template_name, bool|string $f
* @param string $fileName The name of the file to load.
* @param array $params An array of parameters. Keys are the following:
*
* - ['external'] (true/false): Whether the file is a externally located
* - ['external'] (true/false): Whether the file is an externally located
* file. Needs to be set to true if you are loading an external file.
*
* - ['default_theme'] (true/false): Force use of default theme URL.
Expand Down Expand Up @@ -487,7 +487,7 @@ public static function loadCSSFile(string $fileName, array $params = [], string

// Is this a local file?
if (empty($params['external'])) {
// Are we validating the the file exists?
// Are we validating that the file exists?
if (!empty($params['validate']) && ($mtime = @filemtime(self::$current->settings[$themeRef . '_dir'] . '/css/' . $fileName)) === false) {
// Maybe the default theme has it?
if ($themeRef === 'theme' && !$params['force_current'] && ($mtime = @filemtime(self::$current->settings['default_theme_dir'] . '/css/' . $fileName) !== false)) {
Expand Down Expand Up @@ -567,7 +567,7 @@ public static function addInlineCss(string $css): bool
* @param string $fileName The name of the file to load
* @param array $params An array of parameters. Keys are the following:
*
* - ['external'] (true/false): Whether the file is a externally located
* - ['external'] (true/false): Whether the file is an externally located
* file. Needs to be set to true if you are loading an external file.
*
* - ['default_theme'] (true/false): Force use of default theme URL.
Expand Down
2 changes: 1 addition & 1 deletion Sources/Time.php
Original file line number Diff line number Diff line change
Expand Up @@ -1280,7 +1280,7 @@ protected static function datetimePartialFormat(string $type, string $format): s
* Figures out whether the passed format is a strftime format.
*
* @param string $format The format string.
* @return bool Whether is is a strftime format.
* @return bool Whether it is a strftime format.
*/
protected static function isStrftimeFormat(string $format): bool
{
Expand Down
2 changes: 1 addition & 1 deletion Sources/Uuid.php
Original file line number Diff line number Diff line change
Expand Up @@ -406,7 +406,7 @@ public static function create(?int $version = null, mixed $input = null): Uuid
}

/**
* Creates a instance of this class from an existing UUID string.
* Creates an instance of this class from an existing UUID string.
*
* If the input UUID string is invalid, behaviour depends on the $strict
* parameter:
Expand Down
2 changes: 1 addition & 1 deletion Themes/default/GenericControls.template.php
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ function template_control_richedit_buttons($editor_id)
<input type="submit" value="', isset($editor_context['labels']['post_button']) ? $editor_context['labels']['post_button'] : Lang::$txt['post'], '" name="post" tabindex="', --$tempTab, '" onclick="return submitThisOnce(this);" accesskey="s" class="button">
</span>';

// Start an instance of the auto saver if its enabled
// Start an instance of the auto saver if it's enabled
if (!empty(Utils::$context['drafts_save']) && !empty(Utils::$context['drafts_autosave']))
echo '
<span class="righttext padding" style="display: block">
Expand Down
2 changes: 1 addition & 1 deletion Themes/default/Packages.template.php
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ function template_view_package()
</div>
<table class="table_grid">';

// Loop through each theme and display it's name, and then it's details.
// Loop through each theme and display its name, and then it's details.
foreach (Utils::$context['theme_actions'] as $id => $theme)
{
// Pass?
Expand Down
2 changes: 1 addition & 1 deletion Themes/default/PersonalMessage.template.php
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ function loadLabelChoices()
<br>';
}

// Individual messages = buttom list!
// Individual messages = button list!
if (Utils::$context['display_mode'] == 1)
{
template_subject_list();
Expand Down
2 changes: 1 addition & 1 deletion Themes/default/Profile.template.php
Original file line number Diff line number Diff line change
Expand Up @@ -532,7 +532,7 @@ function template_showPosts()
else
template_show_list('attachments');

// No posts? Just end with a informative message.
// No posts? Just end with an informative message.
if ((isset(Utils::$context['attachments']) && empty(Utils::$context['attachments'])) || (!isset(Utils::$context['attachments']) && empty(Utils::$context['posts'])))
echo '
<div class="windowbg">
Expand Down
2 changes: 1 addition & 1 deletion Themes/default/scripts/suggest.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// This file contains javascript associated with a autosuggest control
// This file contains javascript associated with an autosuggest control
function smc_AutoSuggest(oOptions)
{
this.opt = oOptions;
Expand Down
2 changes: 1 addition & 1 deletion Themes/default/scripts/topic.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ QuickModifyTopic.prototype.modify_topic_show_edit = function (subject)
this.oCurSubjectDiv.onmouseover = function (oEvent) {return this.instanceRef.modify_topic_mouseover(oEvent);};
}

// Yup thats right, save it
// Yup that's right, save it
QuickModifyTopic.prototype.modify_topic_save = function (cur_session_id, cur_session_var)
{
if (!this.bInEditMode)
Expand Down
Loading

0 comments on commit bf6ad0f

Please sign in to comment.