Skip to content

Commit

Permalink
logger in module
Browse files Browse the repository at this point in the history
  • Loading branch information
yzhoubk committed Dec 22, 2023
1 parent 91b207a commit 6bcf982
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions lib/gingr/data_handler.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@
module Gingr
module DataHandler
include Config
include Logging


@spatial_root = ''
@geoserver_root = ''
@processing_root = ''

class << self
include Logging
attr_accessor :spatial_root, :geoserver_root, :processing_root

def extract_and_move(zip_file)
Expand All @@ -33,6 +33,9 @@ def extract_zipfile(zip_file, to_dir = @processing_root)
end
end
extracted_to_path
rescue Exception => e
logger.error("Failed to extract #{zip_file}: #{e.message}")
raise
end

def move_files(from_dir_path)
Expand Down

0 comments on commit 6bcf982

Please sign in to comment.