relaton-3gpp 1.14.5 → 1.14.6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 285ae6126d364fe07613776567431dcaa106b52018c4785baf50b2b7bd68e447
4
- data.tar.gz: 82d325c969ab4996f70a41453d8801991cbd42743ce17d50c04e1fc8b278f47d
3
+ metadata.gz: 9bc9709c0a74837fe4f663e26f3fe6a0533f47ac02a265f7fadb18326470e41d
4
+ data.tar.gz: d373bd1f8b947342ff35f022ac4a0228b9b404364d4302cda1ddf8f8ccb9d852
5
5
  SHA512:
6
- metadata.gz: 6b686429f6397496fe7fd8b6cb7fb33f56f8a9eae8fcfc257bd2c3201cc86989e469fddba1e6931eaf504d13796a67b73834d8f6ab9adcdcb7d036f655d88f3b
7
- data.tar.gz: e6838175f1f1040e47be9d1f1610a80df06d8c498270bc89fadae80a0efa5f7c4e0e46a937dca64adf9952ac920c49dfe1a2de6f69e842fb0b5f3348cb796533
6
+ metadata.gz: fe21a29110a3a313d1277d85e5ac6d7dac52ce6637f1bbc31c23b29f167c53bd9b364385e10737ff3eca707736e108d758a2b92fc28b7709502f431ffa285070
7
+ data.tar.gz: 61cac4569e32c91448d550ab3814610164cf34edb948ab818fa8d0e53b76be7377102a27f1d6173e835b54546df2b20e14d27d9ca32c4cc65f09c7776ab5ad20
@@ -72,11 +72,11 @@ module Relaton3gpp
72
72
  end
73
73
 
74
74
  #
75
- # Get file from FTP
75
+ # Get file from FTP. If file does not exist or changed, return nil
76
76
  #
77
77
  # @param [Boolean] renewal force to update all documents
78
78
  #
79
- # @return [String] file name
79
+ # @return [String, nil] file name
80
80
  #
81
81
  def get_file(renewal) # rubocop:disable Metrics/MethodLength, Metrics/AbcSize, Metrics/CyclomaticComplexity, Metrics/PerceivedComplexity
82
82
  @current = YAML.load_file CURRENT if File.exist? CURRENT
@@ -87,7 +87,10 @@ module Relaton3gpp
87
87
  ftp.resume = true
88
88
  ftp.login
89
89
  ftp.chdir "/Information/Databases/Spec_Status/"
90
- d, t, _, file = ftp.list("*.zip").first.split
90
+ file_path = ftp.list("*.zip").first
91
+ return unless file_path
92
+
93
+ d, t, _, file = file_path.split
91
94
  unless renewal
92
95
  dt = DateTime.strptime("#{d} #{t}", "%m-%d-%y %I:%M%p")
93
96
  return if file == @current["file"] && !@current["date"].empty? && dt == DateTime.parse(@current["date"])
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Relaton3gpp
4
- VERSION = "1.14.5"
4
+ VERSION = "1.14.6"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: relaton-3gpp
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.14.5
4
+ version: 1.14.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-06-12 00:00:00.000000000 Z
11
+ date: 2023-06-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: mdb