Skip to content
This repository was archived by the owner on Apr 7, 2020. It is now read-only.

fixed lang does not work #16

Merged
merged 1 commit into from
Sep 28, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/Gracenote.php
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public function getTrackById($id)
{
// need refacotring into everything else.
$this->query_cmd = 'ALBUM_FETCH';
$lang = "<LANG>{strtoupper($this->lang)}</LANG>";
$lang = "<LANG>" . strtoupper($this->lang) . "</LANG>";
$auth = "<AUTH><CLIENT>{$this->client_id}-{$this->client_tag}</CLIENT><USER>{$this->user_id}</USER></AUTH>";
$query = '<QUERY CMD="'.$this->query_cmd.'"><GN_ID>'.$id.'</GN_ID></QUERY>';
$payload = "<QUERIES>{$lang}{$auth}{$query}</QUERIES>";
Expand Down Expand Up @@ -474,7 +474,7 @@ private function formatSearchTrackTitle($raw_albums)
*/
private function xmlPayload()
{
$lang = "<LANG>{strtoupper($this->lang)}</LANG>";
$lang = "<LANG>" . strtoupper($this->lang) . "</LANG>";
$auth = "<AUTH><CLIENT>{$this->client_id}-{$this->client_tag}</CLIENT><USER>{$this->user_id}</USER></AUTH>";
$search = '<TEXT TYPE="'.strtoupper($this->search_type).'">'.$this->search_terms.'</TEXT>';
$query = '<QUERY CMD="'.$this->query_cmd.'">'.$this->search_mode.$search.$this->options.'</QUERY>';
Expand Down