Launcher: a development-build override of the Microsoft endpoint, for the sign-in panel
HORIZON_MSA_MICROSOFT_ENDPOINT (debug builds only) points the device-code and token requests at a local mock, so the restyled code panel can be seen and screenshotted without Microsoft. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -44,8 +44,14 @@ pub struct Endpoints {
|
||||
|
||||
impl Endpoints {
|
||||
pub fn live() -> Self {
|
||||
// Development builds only: `HORIZON_MSA_MICROSOFT_ENDPOINT` points the device-code and
|
||||
// token requests at a local mock, to see and screenshot the sign-in panel.
|
||||
let microsoft = std::env::var("HORIZON_MSA_MICROSOFT_ENDPOINT")
|
||||
.ok()
|
||||
.filter(|_| cfg!(debug_assertions))
|
||||
.unwrap_or_else(|| "https://login.microsoftonline.com/consumers/oauth2/v2.0".into());
|
||||
Self {
|
||||
microsoft: "https://login.microsoftonline.com/consumers/oauth2/v2.0".into(),
|
||||
microsoft,
|
||||
xbox_user: "https://user.auth.xboxlive.com/user/authenticate".into(),
|
||||
xsts: "https://xsts.auth.xboxlive.com/xsts/authorize".into(),
|
||||
minecraft: "https://api.minecraftservices.com".into(),
|
||||
|
||||
Reference in New Issue
Block a user