distributed-press-api-client 0.5.0rc2 → 0.5.0rc4

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
  SHA256:
3
- metadata.gz: b35e83468b6b94652509f9d139cb0e97325f90ed70e1bcc672efbd870017e241
4
- data.tar.gz: fea8338b7a77d4548d51effa48a4b1a4b9b98739c343614ea354b72ac59330d8
3
+ metadata.gz: 5c9c267bf382bc379f9cbcb034747c09eac71af0b8873e3e2b4c45c60120bcf7
4
+ data.tar.gz: b2ffbec67481d7d48687653e2fb7ed76f8bd7f2a587d807b73f3133ef842a655
5
5
  SHA512:
6
- metadata.gz: a90bc42da7610f645c2a1306b3bab87e8eb05a0cc9b562e1702f6d6fb4e1b7d969b5384dc82b03551ae61ee7afa512e38b6a307f77a559a3c5867f569b1be458
7
- data.tar.gz: 54f289f1098da816ef4304e4e3012c5f3a468faf478b5343d4c22b7f7c0a50d0467e96c346bf5d3ac37ac193922ec27fed94cf72106ab1fb0c19704accf0f7c1
6
+ metadata.gz: d06dc678b4bbceb7fa5c061ad3de5fa943108367ddbe48875a0eed24b9fa4e87b6f8af3aeca00d9c29453c75979c97eaf91afde98b0486028edf5cf0ffdad867
7
+ data.tar.gz: 1a67f604b966d5973df3bde6c620d0e3d6aeffbdf57ac723128571e3f9aa784745f1871a3eb6de5f873fb2d617f8a5e95b3b2a93d60b4bdb527e1e50393b80bb
@@ -12,7 +12,7 @@ require_relative 'signed_headers'
12
12
  # Retro-compatibility for URI < 0.12
13
13
  unless URI.respond_to?(:encode_uri_component)
14
14
  URI.class_eval do
15
- def encode_uri_component(str, enc = nil)
15
+ def self.encode_uri_component(str, enc = nil)
16
16
  encode_www_form_component(str, enc || Encoding::UTF_8).gsub('+', '%20')
17
17
  end
18
18
  end
@@ -25,12 +25,14 @@ class DistributedPress
25
25
  #
26
26
  # @param actor_url [String] The URL where the Actor profile is hosted
27
27
  # @param announce [Boolean] Automatically announce new accounts
28
+ # @param manually_approves_followers [Boolean] Automatically accept follow requests
28
29
  # @return [HTTParty::Response]
29
- def create(actor_url, announce = false)
30
+ def create(actor_url, announce: false, manually_approves_followers: false)
30
31
  inbox_body = {
31
32
  'actorUrl' => actor_url,
32
33
  'publicKeyId' => "#{actor_url}#main-key",
33
34
  'announce' => announce,
35
+ 'manuallyApprovesFollowers' => manually_approves_followers,
34
36
  'keypair' => {
35
37
  'publicKeyPem' => client.public_key.public_to_pem,
36
38
  'privateKeyPem' => client.private_key.export
@@ -3,5 +3,5 @@
3
3
  # API client
4
4
  class DistributedPress
5
5
  # Version
6
- VERSION = '0.5.0rc2'
6
+ VERSION = '0.5.0rc4'
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: distributed-press-api-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0rc2
4
+ version: 0.5.0rc4
5
5
  platform: ruby
6
6
  authors:
7
7
  - f
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-06-17 00:00:00.000000000 Z
11
+ date: 2024-07-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: addressable