quiver_note 0.0.6 → 0.0.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/quiver/adapter/dropbox.rb +8 -2
- data/lib/quiver/note.rb +2 -1
- data/lib/quiver_note/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e5a3b1c2f72a6fbf31e86682f1005b9014fadc93
|
4
|
+
data.tar.gz: 648a1f55a2210aebc9c5fad4cd52ccd8cc312b04
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b80982e4f622db1d654242aea75a6d8c91784f91ea298b895f1bc39965090e64a87aa704cb1787b8725ab9c31fbc24b829d85805b3129b85ef8ab3e8ce9b1940
|
7
|
+
data.tar.gz: f20ef3bd34e774e12486002084116c6f7d18863de31ccf7d46974b0a449127fe4b2bd3c62579e5a63896bf312b8512d1290bb785e5b4484409b1f0de129b17bb
|
@@ -1,3 +1,5 @@
|
|
1
|
+
require 'dropbox_api' rescue nil
|
2
|
+
|
1
3
|
if defined? ::DropboxApi
|
2
4
|
|
3
5
|
module Quiver
|
@@ -14,7 +16,7 @@ module Quiver
|
|
14
16
|
# Don't include this url direct on your site. Use via cdn.
|
15
17
|
def image_url(path)
|
16
18
|
@@image_url_cache ||= {}
|
17
|
-
@@image_url_cache[path] ||= client.get_temporary_link(normalize_path(path))
|
19
|
+
@@image_url_cache[path] ||= client.get_temporary_link(normalize_path(path)).link
|
18
20
|
end
|
19
21
|
def each(path)
|
20
22
|
dir_metadata = client.get_metadata(normalize_path(path))
|
@@ -24,7 +26,11 @@ module Quiver
|
|
24
26
|
end
|
25
27
|
end
|
26
28
|
def load(path)
|
27
|
-
|
29
|
+
content = nil
|
30
|
+
meta = client.download(normalize_path(path)) do |con|
|
31
|
+
content = con
|
32
|
+
end
|
33
|
+
[content, meta]
|
28
34
|
end
|
29
35
|
def save(path, content)
|
30
36
|
client.upload normalize_path(path), content
|
data/lib/quiver/note.rb
CHANGED
data/lib/quiver_note/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: quiver_note
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- kuboon
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-10-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|