glossyapp 0.2.1 → 0.2.2

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
  SHA1:
3
- metadata.gz: a3101637d7dde0bba2962921b2f82df29a4269f8
4
- data.tar.gz: bffc4f38b5c4b3ee77b6e9424825b6c2e3fd5cd0
3
+ metadata.gz: 7fd19dfd700e8d9fd1d1a718d7984372e18b66bb
4
+ data.tar.gz: 109bf1c638c4357885d9fea2e80e8af947c4ecb4
5
5
  SHA512:
6
- metadata.gz: ec8480b65123d8680d067e6e26f4a13b1b45bdda4bf1f40743c405f44d733b74fc32461decf600141e1f846d6f0a8311f800b027459eb8f9e4abb700ee4458be
7
- data.tar.gz: ac3dea35f92630bfedf45bc3af4640ec1615a47ac855b4081d753d11df4ec764684d3ffa8021268380e4db3b9313fab05276856db9d0959fec269a070df114ac
6
+ metadata.gz: 7afd647147c88f45665e5785911fd62991cb152f92f2160d8c74120b4e9c5d11c53fa9828354d0cd6de7b3c6ea827409992dae2f2bda7b7927eb709dd363fb07
7
+ data.tar.gz: c74b265f86354fbba571f197e678bc818dd6f26d9c387ec11d7cdb18ac8b6dbdaf1d6b69273a948635d7c3116f8d52e1c8ae8b291b2bf52956af9e92a1e8e8ab
@@ -69,14 +69,10 @@ module GlossyApp
69
69
  data.each_pair { |key, value| post_data[key] = value }
70
70
  files.each_pair { |key, value| post_data[key] = UploadIO.new(File.new(value), 'application/octet-stream', File.basename(value)) }
71
71
 
72
- p post_data
73
-
74
- raise "error"
75
-
76
- # uri = build_uri(path)
77
- # request = Net::HTTP::Post::Multipart.new(uri, post_data)
78
- #
79
- # return make_request(request, headers)
72
+ uri = build_uri(path)
73
+ request = Net::HTTP::Post::Multipart.new(uri, post_data)
74
+
75
+ return make_request(request, headers)
80
76
  end
81
77
 
82
78
  def glossy_delete(path, headers = {})
@@ -79,7 +79,7 @@ module GlossyApp
79
79
  end
80
80
 
81
81
  def publish_document(document_id)
82
- response = glossy_post("/documents/#{document_id}/publish", {})
82
+ response = glossy_post("/documents/#{document_id}/publish", {}.to_json)
83
83
  if [200, 201].include?(response.status)
84
84
  return true
85
85
  else
@@ -88,7 +88,7 @@ module GlossyApp
88
88
  end
89
89
 
90
90
  def unpublish_document(document_id)
91
- response = glossy_post("/documents/#{document_id}/unpublish", {})
91
+ response = glossy_post("/documents/#{document_id}/unpublish", {}.to_json)
92
92
  if [200, 201].include?(response.status)
93
93
  return true
94
94
  else
@@ -1,3 +1,3 @@
1
1
  module GlossyApp
2
- VERSION = "0.2.1"
2
+ VERSION = "0.2.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: glossyapp
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Philipp Schmid