fix: prioritize visitor_data argument before opts
This commit is contained in:
parent
484ac59e0a
commit
a8c7823d44
1 changed files with 2 additions and 2 deletions
|
|
@ -1193,7 +1193,7 @@ impl RustyPipeQuery {
|
||||||
} else {
|
} else {
|
||||||
(Language::En, Country::Us)
|
(Language::En, Country::Us)
|
||||||
};
|
};
|
||||||
let visitor_data = self.opts.visitor_data.as_deref().or(visitor_data);
|
let visitor_data = visitor_data.or(self.opts.visitor_data.as_deref());
|
||||||
|
|
||||||
match ctype {
|
match ctype {
|
||||||
ClientType::Desktop => YTContext {
|
ClientType::Desktop => YTContext {
|
||||||
|
|
@ -1514,7 +1514,7 @@ impl RustyPipeQuery {
|
||||||
id,
|
id,
|
||||||
lang: self.opts.lang,
|
lang: self.opts.lang,
|
||||||
deobf,
|
deobf,
|
||||||
visitor_data,
|
visitor_data: visitor_data.or(self.opts.visitor_data.as_deref()),
|
||||||
client_type: ctype,
|
client_type: ctype,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
Reference in a new issue