From c7700d1e1d815ea23ee80015de76c4c2758752fa Mon Sep 17 00:00:00 2001 From: luzpaz Date: Wed, 5 Mar 2025 19:28:41 -0500 Subject: [PATCH] fix: various typos (#2593) Found via `codespell -q 3 -S "./tests-legacy,./package-lock.json,./cspell.json" -L filp,ridiculus,serie` Co-authored-by: Adam Daley --- Dockerfile | 2 +- src/library/Box/EventDispatcher.php | 1 + src/library/Box/Exception.php | 2 +- src/library/Box/LogDb.php | 2 +- src/library/Payment/Adapter/Custom.php | 2 +- src/library/Registrar/Adapter/Custom.php | 2 +- src/library/Registrar/AdapterAbstract.php | 2 +- src/modules/System/Service.php | 4 ++-- src/themes/huraga/assets/scss/huraga.scss | 2 +- 9 files changed, 10 insertions(+), 9 deletions(-) diff --git a/Dockerfile b/Dockerfile index d20df7bb9..e8421dd45 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ FROM php:8.4-apache -# Install required packages, configure Apache, install PHP exensions, and clean-up. +# Install required packages, configure Apache, install PHP extensions, and clean-up. RUN apt-get update \ && apt-get install -y --no-install-recommends wget unzip zlib1g-dev libpng-dev libicu-dev libbz2-dev \ && a2enmod rewrite \ diff --git a/src/library/Box/EventDispatcher.php b/src/library/Box/EventDispatcher.php index 831cc1c96..59576d5ab 100644 --- a/src/library/Box/EventDispatcher.php +++ b/src/library/Box/EventDispatcher.php @@ -28,6 +28,7 @@ class Box_EventDispatcher } /** + * Notifies all listeners of a given event. * * @param Box_Event $event A Box_Event instance diff --git a/src/library/Box/Exception.php b/src/library/Box/Exception.php index 34704c31d..c23ecaf48 100644 --- a/src/library/Box/Exception.php +++ b/src/library/Box/Exception.php @@ -23,7 +23,7 @@ class Box_Exception extends FOSSBilling\Exception public function __construct(string $message, ?array $variables = null, int $code = 0, bool $protected = false) { // Pass the message to the parent - trigger_error('Box_Exception is deprectated and soon to be removed.', E_USER_DEPRECATED); + trigger_error('Box_Exception is deprecated and soon to be removed.', E_USER_DEPRECATED); parent::__construct($message, $variables, $code, $protected); } } diff --git a/src/library/Box/LogDb.php b/src/library/Box/LogDb.php index 1c4e6d18b..4d8ddcdab 100644 --- a/src/library/Box/LogDb.php +++ b/src/library/Box/LogDb.php @@ -26,7 +26,7 @@ class Box_LogDb */ public function write(array $event, string $channel = 'application'): void { - // TOOD: Temporary! Redo logging stuff in more depth for a major release. + // TODO: Temporary! Redo logging stuff in more depth for a major release. if (in_array($channel, $this->ignoredChannels)) { return; } diff --git a/src/library/Payment/Adapter/Custom.php b/src/library/Payment/Adapter/Custom.php index d428c7e85..dcc68d1da 100644 --- a/src/library/Payment/Adapter/Custom.php +++ b/src/library/Payment/Adapter/Custom.php @@ -107,7 +107,7 @@ class Payment_Adapter_Custom $tx->currency = $invoice->currency; $tx->updated_at = date('Y-m-d H:i:s'); - // Store the updated transaction and use its return to indicate a sucsess or failure. + // Store the updated transaction and use its return to indicate a success or failure. return $this->di['db']->store($tx); } catch (Exception) { return false; diff --git a/src/library/Registrar/Adapter/Custom.php b/src/library/Registrar/Adapter/Custom.php index 6e273e242..f715e0cab 100644 --- a/src/library/Registrar/Adapter/Custom.php +++ b/src/library/Registrar/Adapter/Custom.php @@ -27,7 +27,7 @@ class Registrar_Adapter_Custom extends Registrar_AdapterAbstract public static function getConfig() { return [ - 'label' => 'Custom Registrar always responds with positive results. Usefull if no other registrar is suitable.', + 'label' => 'Custom Registrar always responds with positive results. Useful if no other registrar is suitable.', 'form' => [ 'use_whois' => ['radio', [ 'multiOptions' => ['1' => 'Yes', '0' => 'No'], diff --git a/src/library/Registrar/AdapterAbstract.php b/src/library/Registrar/AdapterAbstract.php index 01f39b893..effa81aa4 100644 --- a/src/library/Registrar/AdapterAbstract.php +++ b/src/library/Registrar/AdapterAbstract.php @@ -27,7 +27,7 @@ abstract class Registrar_AdapterAbstract /** * Return array with configuration. * - * Must be overriden in adapter class + * Must be overridden in adapter class * * @return array */ diff --git a/src/modules/System/Service.php b/src/modules/System/Service.php index 8f8e7285c..aca914613 100644 --- a/src/modules/System/Service.php +++ b/src/modules/System/Service.php @@ -325,7 +325,7 @@ class Service if (!$lastErrorReportingNudge) { // The user upgraded from a version that didn't have error reporting functionality, so let's nudge them about it now. return [ - 'text' => 'We\'d apreciate it if you\'d consider opting into error reporting for FOSSBilling. Doing so will help us improve the software and provide you with a better experience. (Message will remain for 15 minutes)', + 'text' => 'We\'d appreciate it if you\'d consider opting into error reporting for FOSSBilling. Doing so will help us improve the software and provide you with a better experience. (Message will remain for 15 minutes)', 'url' => $url, ]; } elseif ((version_compare(SentryHelper::last_change, $lastErrorReportingNudge) === 1) && Config::getProperty('debug_and_monitoring.report_errors', false) && !Version::isPreviewVersion()) { @@ -1006,7 +1006,7 @@ class Service $di = $event->getDi(); try { - // Prune the classmap to remove classes which are no logner on the disk or that have moved. + // Prune the classmap to remove classes which are no longer on the disk or that have moved. $loader = new \FOSSBilling\AutoLoader(); $loader->getAntLoader()->pruneClassmap(); diff --git a/src/themes/huraga/assets/scss/huraga.scss b/src/themes/huraga/assets/scss/huraga.scss index 7048cd9eb..355da843e 100644 --- a/src/themes/huraga/assets/scss/huraga.scss +++ b/src/themes/huraga/assets/scss/huraga.scss @@ -144,4 +144,4 @@ body { } } -// TOOD: Add custom color themes to Huraga. Bootstrap has a great example here: https://getbootstrap.com/docs/5.3/customize/color-modes/#custom-color-modes +// TODO: Add custom color themes to Huraga. Bootstrap has a great example here: https://getbootstrap.com/docs/5.3/customize/color-modes/#custom-color-modes