DEV: Fix typos and outdated comments (#16614)

This commit is contained in:
Jarek Radosz 2022-05-04 08:12:18 +02:00 committed by GitHub
parent 73940fa968
commit 68ccaa3acb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 9 additions and 9 deletions

View File

@ -22,7 +22,7 @@ module.exports = function (defaults) {
insertContentForTestBody: false, insertContentForTestBody: false,
}, },
sourcemaps: { sourcemaps: {
// There seems to be a bug with brocolli-concat when sourcemaps are disabled // There seems to be a bug with broccoli-concat when sourcemaps are disabled
// that causes the `app.import` statements below to fail in production mode. // that causes the `app.import` statements below to fail in production mode.
// This forces the use of `fast-sourcemap-concat` which works in production. // This forces the use of `fast-sourcemap-concat` which works in production.
enabled: true, enabled: true,

View File

@ -241,7 +241,6 @@ export function discourseModule(name, options) {
export function addPretenderCallback(name, fn) { export function addPretenderCallback(name, fn) {
if (name && fn) { if (name && fn) {
if (_pretenderCallbacks[name]) { if (_pretenderCallbacks[name]) {
// eslint-disable-next-line no-console
throw `There is already a pretender callback with module name (${name}).`; throw `There is already a pretender callback with module name (${name}).`;
} }
@ -572,7 +571,7 @@ export async function paste(element, text, otherClipboardData = {}) {
return e; return e;
} }
// The order of attributes can vary in diffferent browsers. When comparing // The order of attributes can vary in different browsers. When comparing
// HTML strings from the DOM, this function helps to normalize them to make // HTML strings from the DOM, this function helps to normalize them to make
// comparison work cross-browser // comparison work cross-browser
export function normalizeHtml(html) { export function normalizeHtml(html) {

View File

@ -26,6 +26,7 @@ topic:
max: 12 max: 12
overrides: overrides:
# topic titles can be found in config/locales/faker.en.yml # topic titles can be found in config/locales/faker.en.yml
# in the discourse_dev_assets gem
- title: "Coolest thing you have seen today" - title: "Coolest thing you have seen today"
count: 99 count: 99
tags: tags:
@ -36,5 +37,5 @@ user:
count: 30 count: 30
new_user: new_user:
username: new_user username: new_user
email: new_user@example.com email: new_user@example.com

View File

@ -11,7 +11,7 @@ end
if Rails.env.development? && RUBY_VERSION.match?(/^2\.5\.[23]/) if Rails.env.development? && RUBY_VERSION.match?(/^2\.5\.[23]/)
STDERR.puts "WARNING: Discourse development environment runs slower on Ruby 2.5.3 or below" STDERR.puts "WARNING: Discourse development environment runs slower on Ruby 2.5.3 or below"
STDERR.puts "We recommend you upgrade to Ruby 2.6.1 for the optimal development performance" STDERR.puts "We recommend you upgrade to the latest Ruby 2.x for the optimal development performance"
# we have to used to older and slower version of the logger cause the new one exposes a Ruby bug in # we have to used to older and slower version of the logger cause the new one exposes a Ruby bug in
# the Queue class which causes segmentation faults # the Queue class which causes segmentation faults

View File

@ -129,7 +129,7 @@ task 'multisite:migrate' => ['db:load_config', 'environment', 'set_locale'] do |
SeedFu.quiet = true SeedFu.quiet = true
def execute_concurently(concurrency, exceptions) def execute_concurrently(concurrency, exceptions)
queue = Queue.new queue = Queue.new
RailsMultisite::ConnectionManagement.each_connection do |db| RailsMultisite::ConnectionManagement.each_connection do |db|
@ -180,7 +180,7 @@ task 'multisite:migrate' => ['db:load_config', 'environment', 'set_locale'] do |
end end
end end
execute_concurently(concurrency, exceptions) do |db| execute_concurrently(concurrency, exceptions) do |db|
puts "Migrating #{db}" puts "Migrating #{db}"
ActiveRecord::Tasks::DatabaseTasks.migrate ActiveRecord::Tasks::DatabaseTasks.migrate
end end
@ -189,7 +189,7 @@ task 'multisite:migrate' => ['db:load_config', 'environment', 'set_locale'] do |
SeedFu.seed(SeedHelper.paths, /001_refresh/) SeedFu.seed(SeedHelper.paths, /001_refresh/)
execute_concurently(concurrency, exceptions) do |db| execute_concurrently(concurrency, exceptions) do |db|
puts "Seeding #{db}" puts "Seeding #{db}"
SeedFu.seed(SeedHelper.paths, SeedHelper.filter) SeedFu.seed(SeedHelper.paths, SeedHelper.filter)