reddit_api 0.2.0 → 0.3.0
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 +4 -4
- data/lib/reddit_api/subreddits.rb +4 -4
- data/lib/reddit_api/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 7711c2f04b692818db5030e3f17129c777e1378a
|
|
4
|
+
data.tar.gz: e7c895bca02f24142693ada3510d7935d02975fd
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: e66b99d8ad236885d92f87183056f5c1d996f98f64d03deed04809d0ef36412b173ef7ffd79cd45ed0dc87c5d9d329a3dba1ec9bb93b75c942fa96b07d3b5544
|
|
7
|
+
data.tar.gz: 4d4ccef23d3ede9e536837881927ed59d7647a35d71f4aa18c4b7a4003d2c6096cb2d85fa60493f2db7b943b76a2e2cf601530263f18e697d33b312b18d917fe
|
|
@@ -13,8 +13,8 @@ module RedditApi
|
|
|
13
13
|
build_all_subreddits(subreddits_data)
|
|
14
14
|
end
|
|
15
15
|
|
|
16
|
-
def data_for(
|
|
17
|
-
query = build_singular_query(
|
|
16
|
+
def data_for(subreddit_name)
|
|
17
|
+
query = build_singular_query(subreddit_name)
|
|
18
18
|
client.get(query)
|
|
19
19
|
build_subreddit(query.captured_records.first)
|
|
20
20
|
end
|
|
@@ -35,8 +35,8 @@ module RedditApi
|
|
|
35
35
|
resource: :subreddit)
|
|
36
36
|
end
|
|
37
37
|
|
|
38
|
-
def build_singular_query(
|
|
39
|
-
endpoint = "r/#{
|
|
38
|
+
def build_singular_query(subreddit_name)
|
|
39
|
+
endpoint = "r/#{subreddit_name}/about.json"
|
|
40
40
|
query_factory.new(count: 1,
|
|
41
41
|
endpoint: endpoint,
|
|
42
42
|
resource: :subreddit)
|
data/lib/reddit_api/version.rb
CHANGED