Skip to content
Open
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
16 changes: 8 additions & 8 deletions discord/install.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,20 +41,20 @@ func (discord *DiscordInstall) InstallBD(options types.InstallOptions) error {
log.Println("✅ BetterDiscord prepared for install")
log.Println("")

// Download and write betterdiscord.asar
log.Println("📥 Downloading BetterDiscord...")
if err := bd.Download(options.UseDevBuild); err != nil {
// Discord locks app.asar and betterdiscord.asar while running, so it must be stopped before we can
// modify it. Capture the executable so it can be relaunched afterward.
exe, wasRunning, err := discord.stop()
if err != nil {
return err
}
log.Println("✅ BetterDiscord downloaded")
log.Println("")

// Discord locks app.asar while running, so it must be stopped before we can
// modify it. Capture the executable so it can be relaunched afterward.
exe, wasRunning, err := discord.stop()
if err != nil {
// Download and write betterdiscord.asar
log.Println("📥 Downloading BetterDiscord...")
if err := bd.Download(options.UseDevBuild); err != nil {
return err
}
log.Println("✅ BetterDiscord downloaded")
log.Println("")

// Shadow app.asar with our loader
Expand Down