Browse Source

Maintenance: Activated rubocop Layout/LeadingCommentSpace.

Thorsten Eckel 3 years ago
parent
commit
b8b57781b7

+ 0 - 5
.rubocop/default.yml

@@ -81,11 +81,6 @@ Style/RescueStandardError:
   Enabled: true
   EnforcedStyle: implicit
 
-Layout/LeadingCommentSpace:
-  Description: 'Comments should start with a space.'
-  StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#hash-space'
-  Enabled: false
-
 Layout/SpaceInsideReferenceBrackets:
   Description: 'Checks the spacing inside referential brackets.'
   Enabled: false

+ 4 - 4
app/controllers/application_controller/authenticates.rb

@@ -43,10 +43,10 @@ module ApplicationController::Authenticates
   end
 
   def authentication_check_only(auth_param = {})
-    #logger.debug 'authentication_check'
-    #logger.debug params.inspect
-    #logger.debug session.inspect
-    #logger.debug cookies.inspect
+    # logger.debug 'authentication_check'
+    # logger.debug params.inspect
+    # logger.debug session.inspect
+    # logger.debug cookies.inspect
     authentication_errors = []
 
     # already logged in, early exit

+ 1 - 1
app/controllers/application_controller/has_user.rb

@@ -88,7 +88,7 @@ module ApplicationController::HasUser
 
   # update session updated_at
   def session_update
-    #sleep 0.6
+    # sleep 0.6
 
     session[:ping] = Time.zone.now.iso8601
 

+ 6 - 6
app/controllers/first_steps_controller.rb

@@ -7,13 +7,13 @@ class FirstStepsController < ApplicationController
 
   def index
     invite_agents = false
-    #if User.of_role('Agent').count > 2
+    # if User.of_role('Agent').count > 2
     #  invite_agents = true
-    #end
+    # end
     invite_customers = false
-    #if User.of_role('Customer').count > 2
+    # if User.of_role('Customer').count > 2
     #  invite_customers = true
-    #end
+    # end
 
     chat_active = false
     if Setting.get('chat')
@@ -98,11 +98,11 @@ class FirstStepsController < ApplicationController
               checked:  macro_active,
               location: '#manage/macros',
             },
-            #{
+            # {
             #  name: 'Create Overviews',
             #  checked: false,
             #  location: '#manage/overviews',
-            #},
+            # },
           ],
         },
         {

+ 1 - 1
app/controllers/getting_started_controller.rb

@@ -211,7 +211,7 @@ curl http://localhost/api/v1/getting_started -v -u #{login}:#{password}
   end
 
   def setup_done
-    #return false
+    # return false
     count = User.all.count()
     done = true
     if count <= 2

+ 2 - 2
app/controllers/long_polling_controller.rb

@@ -64,7 +64,7 @@ class LongPollingController < ApplicationController
       4.times do
         sleep 0.25
       end
-      #sleep 1
+      # sleep 1
       Sessions.touch(client_id) # rubocop:disable Rails/SkipsModelValidations
 
       # set max loop time to 24 sec. because of 30 sec. timeout of mod_proxy
@@ -83,7 +83,7 @@ class LongPollingController < ApplicationController
         8.times do
           sleep 0.25
         end
-        #sleep 2
+        # sleep 2
         if count.zero?
           render json: { event: 'pong' }
           return

+ 1 - 1
app/jobs/application_job/has_delayed_job_monitoring_compatibilty.rb

@@ -11,7 +11,7 @@ class ApplicationJob
       # until we resolve this dependency.
       after_enqueue do |job|
         # skip update of `attempts` attribute if job wasn't queued because of ActiveJobLock
-        #(another job with same lock key got queued before this job could be retried)
+        # (another job with same lock key got queued before this job could be retried)
         next if job.provider_job_id.blank?
 
         # update the column right away without loading Delayed::Job record

+ 1 - 1
app/jobs/communicate_telegram_job.rb

@@ -24,7 +24,7 @@ class CommunicateTelegramJob < ApplicationJob
       channel = Channel.lookup(id: ticket.preferences['channel_id'])
     end
     log_error(article, "No such channel for bot #{ticket.preferences['bid']} or channel id #{ticket.preferences['channel_id']}") if !channel
-    #log_error(article, "Channel.find(#{channel.id}) isn't a telegram channel!") if channel.options[:adapter] !~ /\Atelegram/i
+    # log_error(article, "Channel.find(#{channel.id}) isn't a telegram channel!") if channel.options[:adapter] !~ /\Atelegram/i
     log_error(article, "Channel.find(#{channel.id}) has not telegram api token!") if channel.options[:api_token].blank?
 
     begin

+ 1 - 1
app/models/calendar.rb

@@ -423,7 +423,7 @@ returns
       return
     end
 
-    #raise Exceptions::UnprocessableEntity, 'No configured business hours found!' if hours.blank?
+    # raise Exceptions::UnprocessableEntity, 'No configured business hours found!' if hours.blank?
 
     # validate if business hours are usable by execute a try calculation
     begin

+ 1 - 1
app/models/channel.rb

@@ -174,7 +174,7 @@ stream all accounts
           end
         end
 
-        #logger.info "thread stream for channel (#{channel.id}) already running" if @@channel_stream[channel_id].present?
+        # logger.info "thread stream for channel (#{channel.id}) already running" if @@channel_stream[channel_id].present?
         next if @@channel_stream[channel_id].present?
 
         @@channel_stream[channel_id] = {

Some files were not shown because too many files changed in this diff