board-game-gem 0.3.2 → 0.3.3

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: 3bac40072c12ed03715482d0da9fb1cccf8985f4
4
- data.tar.gz: 62fe6d81dc76c25613afa756d629b788ecf825f7
3
+ metadata.gz: 457495ab88acb1153e8f05a12cc92dfd32815e68
4
+ data.tar.gz: 4227221f65bb5ad82ef0db3d15fe41d029c863a3
5
5
  SHA512:
6
- metadata.gz: 2e81c46c8d05188b8fc7f594f2147afb9c4237ac5f22f7d5fb6178ea50aadd9ad409023f281a3e30406cd168bc9eaaf2a3791846bd898a9bd1e8f783b01f3751
7
- data.tar.gz: f20b4f858a09307d4b54053027c641e9a00b4f7b9c7434674421575908814239938ed23a5dcddb0df45552efb4f8d6852ee70f30b8d7a62cf4e9435318394849
6
+ metadata.gz: 561c7b2d53dab5e564188923ff97b1dcbfd5b55ffdd525870305de8926b161e859f2e873d43a1cde95df65011a04de011660bba8ed6e3119187d35ebd1d02b6a
7
+ data.tar.gz: 2bbb0d7cd1e80a1c146db51e7cb591f42732239b4af3cb63ad4badf6865291aa0464380a85c34011af174304c58519e13ab00a749d57864b36310014a43fbd05
data/lib/boardgamegem.rb CHANGED
@@ -10,7 +10,7 @@ module BoardGameGem
10
10
  options[:id] = id
11
11
  options[:stats] = statistics ? 1 : 0
12
12
  item = BGGItem.new(BoardGameGem.request_xml("thing", options))
13
- return item.id == 0 ? nil : item
13
+ item.id == 0 ? nil : item
14
14
  end
15
15
 
16
16
  def BoardGameGem.get_items(ids, statistics = false, options = {})
@@ -28,29 +28,29 @@ module BoardGameGem
28
28
  def BoardGameGem.get_family(id, options = {})
29
29
  options[:id] = id
30
30
  family = BGGFamily.new(BoardGameGem.request_xml("family", options))
31
- return family.id == 0 ? nil : family
31
+ family.id == 0 ? nil : family
32
32
  end
33
33
 
34
34
  def BoardGameGem.get_user(username, options = {})
35
35
  options[:name] = username
36
36
  user = BGGUser.new(BoardGameGem.request_xml("user", options))
37
- return user.id == 0 ? nil : user
37
+ user.id == 0 ? nil : user
38
38
  end
39
39
 
40
40
  def BoardGameGem.get_collection(username, options = {})
41
41
  options[:username] = username
42
42
  collection_xml = BoardGameGem.request_xml("collection", options)
43
43
  if collection_xml.css("error").length > 0
44
- return nil
44
+ nil
45
45
  else
46
- return BGGCollection.new(collection_xml)
46
+ BGGCollection.new(collection_xml)
47
47
  end
48
48
  end
49
49
 
50
50
  def BoardGameGem.search(query, options = {})
51
51
  options[:query] = query
52
52
  xml = BoardGameGem.request_xml("search", options)
53
- return {
53
+ {
54
54
  :total => xml.at_css("items")["total"].to_i,
55
55
  :items => xml.css("item").map { |x| BGGSearchResult.new(x) }
56
56
  }
@@ -1,3 +1,3 @@
1
1
  module BoardGameGem
2
- VERSION = "0.3.2"
2
+ VERSION = "0.3.3"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: board-game-gem
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.2
4
+ version: 0.3.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jake Roussel