Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Switch to GitLab Next
Sign in / Register
Toggle navigation
Open sidebar
Francis
Blizzard api
Commits
fc4c2c7b
Commit
fc4c2c7b
authored
Apr 17, 2020
by
Francis
Browse files
Fixed D3 item URL
parent
3774ba08
Pipeline
#137350971
passed with stage
in 5 minutes and 7 seconds
Changes
4
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
5 deletions
+8
-5
CHANGELOG.md
CHANGELOG.md
+4
-0
lib/blizzard_api/diablo/community/item.rb
lib/blizzard_api/diablo/community/item.rb
+2
-3
lib/blizzard_api/version.rb
lib/blizzard_api/version.rb
+1
-1
test/blizzard/diablo/community/item_test.rb
test/blizzard/diablo/community/item_test.rb
+1
-1
No files found.
CHANGELOG.md
View file @
fc4c2c7b
Please view this file on the master branch, otherwise it may be outdated
**Version 0.3.11**
Fixed D3 item URL.
**Version 0.3.10**
Really fixed D3 profile URLs this time.
...
...
lib/blizzard_api/diablo/community/item.rb
View file @
fc4c2c7b
...
...
@@ -14,12 +14,11 @@ module BlizzardApi
# Return information about an item
#
# @param item_slug [String] Item slug
# @param item_id [Integer] Item id
# @!macro request_options
#
# @!macro response
def
get
(
item_slug
,
item
_id
,
options
=
{})
api_request
"
#{
base_url
(
:community
)
}
/data/item/
#{
item_slug
}
-
#{
item
_id
}
"
,
{
ttl:
CACHE_TRIMESTER
}.
merge
(
options
)
def
get
(
item_slug
_and
_id
,
options
=
{})
api_request
"
#{
base_url
(
:community
)
}
/data/item/
#{
item_slug
_and
_id
}
"
,
{
ttl:
CACHE_TRIMESTER
}.
merge
(
options
)
end
end
end
...
...
lib/blizzard_api/version.rb
View file @
fc4c2c7b
...
...
@@ -2,5 +2,5 @@
module
BlizzardApi
# Gem version
VERSION
=
'0.3.1
0
'
VERSION
=
'0.3.1
1
'
end
test/blizzard/diablo/community/item_test.rb
View file @
fc4c2c7b
...
...
@@ -12,7 +12,7 @@ module BlizzardApi
end
def
test_item_get
item_data
=
@item
.
get
'corrupted-ashbringer
'
,
'
Unique_Sword_2H_104_x1'
item_data
=
@item
.
get
'corrupted-ashbringer
-
Unique_Sword_2H_104_x1'
assert_equal
'unique_sword_2h_104_x1_demonhunter_male'
,
item_data
[
:icon
]
end
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment