goliath 1.0.6 → 1.0.7
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of goliath might be problematic. Click here for more details.
- checksums.yaml +5 -5
- data/examples/rasterize/rasterize.rb +1 -1
- data/lib/goliath/connection.rb +1 -1
- data/lib/goliath/rack/templates.rb +1 -1
- data/lib/goliath/response.rb +1 -1
- data/lib/goliath/server.rb +1 -1
- data/lib/goliath/version.rb +1 -1
- metadata +6 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: dfbb6334b545d1cb281c256ecc8d127158b28ec6d2f9fdb5f75480d34444dc9d
|
4
|
+
data.tar.gz: 5a755161caf7c6ef1877197066ac628cec01211e247f452e6bf5ff65eb6ca3a1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a56de2b0212a2e749a822b796040ce36bc318adcb20d347c825e426acf9eb7958525b74447a9f4e9e5273fb0b58398a8f92aaf9bbf0c45c5886d97fea002e079
|
7
|
+
data.tar.gz: 56c4b36ebfceabff78951ef70f71807215cba80ee27e985969899005fc7a0e0397b3df52617079b2172ca74cf14416e90adfc652a8d12e81e8e1a6fabe2c90b4
|
@@ -17,7 +17,7 @@ class Rasterize < Goliath::API
|
|
17
17
|
url = PostRank::URI.clean(params['url'])
|
18
18
|
hash = PostRank::URI.hash(url, :clean => false)
|
19
19
|
|
20
|
-
if !File.
|
20
|
+
if !File.exist? filename(hash)
|
21
21
|
fiber = Fiber.current
|
22
22
|
EM.system('phantomjs rasterize.js ' + url.to_s + ' ' + filename(hash)) do |output, status|
|
23
23
|
env.logger.info "Phantom exit status: #{status}"
|
data/lib/goliath/connection.rb
CHANGED
@@ -251,7 +251,7 @@ module Goliath
|
|
251
251
|
# @return [String | nil] Template file or nil if it doesn't exist.
|
252
252
|
def find_template(views, name, engine)
|
253
253
|
filename = ::File.join(views, "#{name}.#{engine}")
|
254
|
-
File.
|
254
|
+
File.exist?(filename) ? filename : nil
|
255
255
|
end
|
256
256
|
|
257
257
|
# Renders a template with the given engine. Don't call this directly --
|
data/lib/goliath/response.rb
CHANGED
data/lib/goliath/server.rb
CHANGED
@@ -132,7 +132,7 @@ module Goliath
|
|
132
132
|
def load_config(file = nil)
|
133
133
|
api_name = api.class.to_s.gsub('::', '_').gsub(/([^_A-Z])([A-Z])/,'\1_\2').downcase!
|
134
134
|
file ||= "#{config_dir}/#{api_name}.rb"
|
135
|
-
return unless File.
|
135
|
+
return unless File.exist?(file)
|
136
136
|
|
137
137
|
proc = Proc.new {} # create proc to grab binding
|
138
138
|
eval(IO.read(file), proc.binding, file)
|
data/lib/goliath/version.rb
CHANGED
metadata
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: goliath
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- dan sinclair
|
8
8
|
- Ilya Grigorik
|
9
|
-
autorequire:
|
9
|
+
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2023-10-08 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: eventmachine
|
@@ -660,7 +660,7 @@ files:
|
|
660
660
|
homepage: http://goliath.io/
|
661
661
|
licenses: []
|
662
662
|
metadata: {}
|
663
|
-
post_install_message:
|
663
|
+
post_install_message:
|
664
664
|
rdoc_options: []
|
665
665
|
require_paths:
|
666
666
|
- lib
|
@@ -675,9 +675,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
675
675
|
- !ruby/object:Gem::Version
|
676
676
|
version: '0'
|
677
677
|
requirements: []
|
678
|
-
|
679
|
-
|
680
|
-
signing_key:
|
678
|
+
rubygems_version: 3.1.6
|
679
|
+
signing_key:
|
681
680
|
specification_version: 4
|
682
681
|
summary: Async framework for writing API servers
|
683
682
|
test_files:
|