ucb_rails_session_timeout 1.0.0 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: eec79400b51768c1573bed8ff84536507dbc9e1b4f46bde74f14c01b20888498
4
- data.tar.gz: 5e6f7db2019778890f0b9e21684adf69d357160bec91d8fa68b271888e6daaf7
3
+ metadata.gz: a619c7ea2409509cbc9a820fe0c63e847919628fd50923da0d551ae4e4e90562
4
+ data.tar.gz: 7b74943438d74434493eebd3b1ee4f88bbf342966a0522c1fd541d4863877501
5
5
  SHA512:
6
- metadata.gz: 8751d53d5f07d428f571f534b52e886a26af511346f68240f6e4947ae4e9f3dee1ea4c9ffe48e2fa5dc21a25ed89652108660da757f0c5d6c10c49e998ddedd1
7
- data.tar.gz: 216d18fd7232bbe2f06a1149d2f6ac2679f61f94852822526c917bd225bb23fbc3d436e35eba75acd93ac4cd97a53f91dfbc09573744e49e8df62afb28eaf227
6
+ metadata.gz: 4fb0be610b1155e8777b399e843e396a9276727f8fc794834b7becabbc03825c9c70e407a820669572792a41fc7a672f188821fb07eb2a11d03462c5cbf7a573
7
+ data.tar.gz: 9e17a95441a336ed51a1cb14ec0db22576e52feb29d78ae99c591bf20f935aaf485585c44a8bf2afa6251a68031fafd5d76db84edb8ac42d96c29b2f035c64a4
data/CHANGELOG.md CHANGED
@@ -1,3 +1,6 @@
1
- ## [1.0.0] - 2025-02-27
1
+ ## 1.0.1 - 2025-11-13
2
+ - Fixes issues where server runs in Pacific time zone and client could run in other zones leading to premature timeout
3
+ - Fixes issues with assets not being automatically discoverable by consuming app
2
4
 
3
- - Initial release
5
+ ## [1.0.0] - 2025-02-27
6
+ - Initial release
@@ -19,12 +19,12 @@ module UcbRailsSessionTimeout
19
19
  private
20
20
 
21
21
  def track_activity
22
- session[:last_active_at] = Time.current.strftime("%d/%m/%Y, %H:%M:%S")
22
+ session[:last_active_at] = Time.zone.now.strftime("%d/%m/%Y, %H:%M:%S")
23
23
  end
24
24
 
25
25
  def check_timeout
26
26
  return if session[:last_active_at].blank?
27
- time_since_last_activity = Time.current - Time.parse(session[:last_active_at])
27
+ time_since_last_activity = Time.current - Time.zone.parse(session[:last_active_at])
28
28
  if time_since_last_activity > (UcbRailsSessionTimeout.configuration.timeout_length + GRACE_PERIOD)
29
29
  reset_session
30
30
  handle_session_timeout()
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module UcbRailsSessionTimeout
4
- VERSION = "1.0.0"
4
+ VERSION = "1.0.1"
5
5
  end
@@ -7,6 +7,10 @@ module UcbRailsSessionTimeout
7
7
  class Error < StandardError; end
8
8
 
9
9
  class Engine < ::Rails::Engine
10
+ # Add gem's app/javascript to asset paths for Propshaft
11
+ initializer "ucb_rails_session_timeout.assets" do |app|
12
+ app.config.assets.paths << root.join("app/javascript")
13
+ end
10
14
  end
11
15
 
12
16
  def self.included(base)
metadata CHANGED
@@ -1,15 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ucb_rails_session_timeout
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Darin Wilson
8
8
  - Michael Valenza
9
- autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2025-02-28 00:00:00.000000000 Z
11
+ date: 1980-01-02 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: rails
@@ -67,7 +66,6 @@ metadata:
67
66
  homepage_uri: https://gitlab.com/ucb-bit/cad/aa/ucb_rails_session_timeout
68
67
  source_code_uri: https://gitlab.com/ucb-bit/cad/aa/ucb_rails_session_timeout
69
68
  changelog_uri: https://gitlab.com/ucb-bit/cad/aa/ucb_rails_session_timeout/-/blob/main/CHANGELOG.md
70
- post_install_message:
71
69
  rdoc_options: []
72
70
  require_paths:
73
71
  - lib
@@ -82,8 +80,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
82
80
  - !ruby/object:Gem::Version
83
81
  version: '0'
84
82
  requirements: []
85
- rubygems_version: 3.5.3
86
- signing_key:
83
+ rubygems_version: 3.6.9
87
84
  specification_version: 4
88
85
  summary: Auto-logout functionality for Rails applications
89
86
  test_files: []