merb_sequel 0.4.0 → 0.4.1
Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile
CHANGED
@@ -3,15 +3,15 @@ module Merb
|
|
3
3
|
def setup_session
|
4
4
|
MERB_LOGGER.info("Setting up session")
|
5
5
|
before = cookies[_session_id_key]
|
6
|
-
|
7
|
-
@_fingerprint = Marshal.dump(
|
6
|
+
request.session, cookies[_session_id_key] = Merb::SequelSession.persist(cookies[_session_id_key])
|
7
|
+
@_fingerprint = Marshal.dump(request.session.data).hash
|
8
8
|
@_new_cookie = cookies[_session_id_key] != before
|
9
9
|
end
|
10
10
|
|
11
11
|
def finalize_session
|
12
12
|
MERB_LOGGER.info("Finalize session")
|
13
|
-
|
14
|
-
set_cookie(_session_id_key,
|
13
|
+
request.session.save if @_fingerprint != Marshal.dump(request.session.data).hash
|
14
|
+
set_cookie(_session_id_key, request.session.values[:session_id], _session_expiry) if (@_new_cookie || request.session.needs_new_cookie)
|
15
15
|
end
|
16
16
|
end
|
17
17
|
|
metadata
CHANGED
@@ -1,10 +1,10 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
|
-
rubygems_version: 0.9.
|
2
|
+
rubygems_version: 0.9.2
|
3
3
|
specification_version: 1
|
4
4
|
name: merb_sequel
|
5
5
|
version: !ruby/object:Gem::Version
|
6
|
-
version: 0.4.
|
7
|
-
date: 2007-11-
|
6
|
+
version: 0.4.1
|
7
|
+
date: 2007-11-12 00:00:00 -06:00
|
8
8
|
summary: Merb plugin that provides support for the Sequel database object
|
9
9
|
require_paths:
|
10
10
|
- lib
|
@@ -34,37 +34,37 @@ files:
|
|
34
34
|
- Rakefile
|
35
35
|
- TODO
|
36
36
|
- lib/merb
|
37
|
+
- lib/merb_sequel.rb
|
38
|
+
- lib/merbtasks.rb
|
37
39
|
- lib/merb/orms
|
40
|
+
- lib/merb/session
|
38
41
|
- lib/merb/orms/sequel
|
39
42
|
- lib/merb/orms/sequel/connection.rb
|
40
43
|
- lib/merb/orms/sequel/database.sample.yml
|
41
|
-
- lib/merb/session
|
42
44
|
- lib/merb/session/001_add_sessions_table.rb
|
43
45
|
- lib/merb/session/sequel_session.rb
|
44
|
-
- lib/merb_sequel.rb
|
45
|
-
- lib/merbtasks.rb
|
46
46
|
- specs/merb_sequel_spec.rb
|
47
47
|
- specs/spec_helper.rb
|
48
48
|
- sequel_generators/migration
|
49
|
+
- sequel_generators/model
|
50
|
+
- sequel_generators/resource_controller
|
49
51
|
- sequel_generators/migration/migration_generator.rb
|
50
52
|
- sequel_generators/migration/templates
|
51
|
-
- sequel_generators/migration/templates/new_migration.erb
|
52
53
|
- sequel_generators/migration/USAGE
|
53
|
-
- sequel_generators/
|
54
|
+
- sequel_generators/migration/templates/new_migration.erb
|
54
55
|
- sequel_generators/model/model_generator.rb
|
55
56
|
- sequel_generators/model/templates
|
56
|
-
- sequel_generators/model/templates/sequel_model_template.erb
|
57
57
|
- sequel_generators/model/USAGE
|
58
|
-
- sequel_generators/
|
58
|
+
- sequel_generators/model/templates/sequel_model_template.erb
|
59
59
|
- sequel_generators/resource_controller/resource_controller_generator.rb
|
60
60
|
- sequel_generators/resource_controller/templates
|
61
|
+
- sequel_generators/resource_controller/USAGE
|
61
62
|
- sequel_generators/resource_controller/templates/controller.rb
|
62
63
|
- sequel_generators/resource_controller/templates/edit.html.erb
|
63
64
|
- sequel_generators/resource_controller/templates/helper.rb
|
64
65
|
- sequel_generators/resource_controller/templates/index.html.erb
|
65
66
|
- sequel_generators/resource_controller/templates/new.html.erb
|
66
67
|
- sequel_generators/resource_controller/templates/show.html.erb
|
67
|
-
- sequel_generators/resource_controller/USAGE
|
68
68
|
test_files: []
|
69
69
|
|
70
70
|
rdoc_options: []
|