mirror of
https://github.com/ppy/osu.git
synced 2024-12-13 08:32:57 +08:00
Ensure AssemblyName is never null (seems to be on CI server).
This commit is contained in:
parent
b5aff9df5f
commit
1e48b0a037
@ -1,6 +1,7 @@
|
||||
// Copyright (c) 2007-2017 ppy Pty Ltd <contact@ppy.sh>.
|
||||
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
||||
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
using System.Reflection;
|
||||
using osu.Framework.Allocation;
|
||||
@ -39,7 +40,7 @@ namespace osu.Game
|
||||
|
||||
public readonly Bindable<WorkingBeatmap> Beatmap = new Bindable<WorkingBeatmap>();
|
||||
|
||||
protected AssemblyName AssemblyName => Assembly.GetEntryAssembly().GetName();
|
||||
protected AssemblyName AssemblyName => Assembly.GetEntryAssembly()?.GetName() ?? new AssemblyName() { Version = new Version() };
|
||||
|
||||
public bool IsDeployedBuild => AssemblyName.Version.Major > 0;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user