DEV: enable frozen string literal on all files

This reduces chances of errors where consumers of strings mutate inputs
and reduces memory usage of the app.

Test suite passes now, but there may be some stuff left, so we will run
a few sites on a branch prior to merging
This commit is contained in:
Sam Saffron
2019-05-03 08:17:27 +10:00
committed by Guo Xiang Tan
parent 4e1f25197d
commit 30990006a9
2201 changed files with 4482 additions and 90 deletions

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module Jobs
class DailyPerformanceReport < Jobs::Scheduled
every 1.day

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
class LogAnalyzer
class LineParser

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
# name: discourse-nginx-performance-report
# about: Analyzing Discourse Performance using NGINX logs
# version: 0.1

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require 'date'
require_relative '../lib/log_analyzer'

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require 'rails_helper'
require_relative '../lib/log_analyzer'