teepee 0.7.1 → 0.7.2

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
  SHA1:
3
- metadata.gz: 078d2a283aa77f2d063b28429705d32caa7f9c8b
4
- data.tar.gz: 6fabf91efb512af6d360879b6ee99762a5c7c87b
3
+ metadata.gz: 6012026e9d404aa4d6e7a86b308037813da026dd
4
+ data.tar.gz: 1b71d7676cad4e1a89ed0fa234981f1b442a7b44
5
5
  SHA512:
6
- metadata.gz: 09af3c2f9ec62332a301fb696404ac06ad172c2c47744e743af3bae4189b9121b8b2fd55ad1a20e61e9ae842c80cbf78ddeb253b6fbcef4eca92a9832071bb9e
7
- data.tar.gz: b8e134e7f8de13319aff5bfd6ad885ea2b79b8533fe3deb9b171150cba87abc911c4161b5b89bd9e792ed3c19b617b64d821c58505c4886ac9f2b5a2e427f32b
6
+ metadata.gz: 445c0d6f99d1ce687a91403575ad031f4bf65e6d75bba1c209e59ff773354fb3936323593ff8f08ba9374cf1ec03c5c136e0c00e0398db8e1dfe7c68a14d62ad
7
+ data.tar.gz: ba267077bb69a1267c9b4007477fba4100f907a397940733bd1174615da17d1535f2872c63d74388051fce082c2299aa07bfcde7f4183678ed442b412c5069ea
data/lib/teepee.rb CHANGED
@@ -38,11 +38,11 @@
38
38
  module Teepee
39
39
  end
40
40
 
41
- include ERB::Util
42
-
43
41
  require 'active_support/all'
44
42
  require 'monkey-patch'
45
43
 
44
+ include ERB::Util
45
+
46
46
  require 'teepee/constants'
47
47
  require 'teepee/errors'
48
48
  require 'teepee/parser-node'
@@ -62,7 +62,7 @@ module Teepee
62
62
  elsif not id.to_s =~ /\A[0-9]+\z/
63
63
  command_error "#{singular}_id: error: invalid #{singular} ID specified"
64
64
  else
65
- thing = klass.find Integer(id.to_s)
65
+ thing = eval(klass.to_s).find Integer(id.to_s)
66
66
  if thing
67
67
  @action_view.render partial: partial,
68
68
  locals: {singular.to_sym => thing}
@@ -82,7 +82,7 @@ module Teepee
82
82
  elsif not id.to_s =~ /\A[0-9]+\z/
83
83
  command_error "#{singular}_id: error: invalid #{singular} ID specified"
84
84
  else
85
- tb_href "/#{plural}/#{id.to_s}/#{view}", "#{klass} ##{id.to_s}"
85
+ tb_href "/#{plural}/#{id.to_s}/#{view}", "#{klass.to_s} ##{id.to_s}"
86
86
  end
87
87
  end
88
88
 
@@ -157,7 +157,7 @@ module Teepee
157
157
  end
158
158
 
159
159
  def bookmarks_folder_id id
160
- id_command_handler id, Folder, "folder", "folders", "folders/bookmarks_inline", "bookmarks"
160
+ id_command_handler id, :Folder, "folder", "folders", "folders/bookmarks_inline", "bookmarks"
161
161
  end
162
162
 
163
163
  def br
@@ -193,11 +193,11 @@ module Teepee
193
193
  end
194
194
 
195
195
  def folder_id id
196
- id_command_handler id, Folder
196
+ id_command_handler id, :Folder
197
197
  end
198
198
 
199
199
  def forum_id id
200
- id_command_handler id, Forum
200
+ id_command_handler id, :Forum
201
201
  end
202
202
 
203
203
  def gamma number
@@ -232,8 +232,8 @@ module Teepee
232
232
  ensure_numeric Math::lgamma(n).first
233
233
  end
234
234
 
235
- def link_id
236
- id_command_handler id, Link
235
+ def link_id id
236
+ id_command_handler id, :Link
237
237
  end
238
238
 
239
239
  def ln number
@@ -290,7 +290,7 @@ module Teepee
290
290
  end
291
291
 
292
292
  def tag_id id
293
- id_command_handler id, Tag
293
+ id_command_handler id, :Tag
294
294
  end
295
295
 
296
296
  def tan angle
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: teepee
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.1
4
+ version: 0.7.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Christopher Mark Gore
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-12-11 00:00:00.000000000 Z
11
+ date: 2015-12-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -77,7 +77,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
77
77
  version: '0'
78
78
  requirements: []
79
79
  rubyforge_project:
80
- rubygems_version: 2.4.5.1
80
+ rubygems_version: 2.2.2
81
81
  signing_key:
82
82
  specification_version: 4
83
83
  summary: Teepee is a markup language for ThinkingBicycle.com.