Browse Source

Fixed issue with empty headers

tags/v0.16.5
Frans Bouma 6 years ago
parent
commit
5b76a688b5
2 changed files with 18 additions and 7 deletions
  1. +16
    -5
      src/DocNet/Config.cs
  2. +2
    -2
      src/DocNet/Properties/AssemblyInfo.cs

+ 16
- 5
src/DocNet/Config.cs View File

@@ -275,13 +275,24 @@ namespace Docnet
{ {
if(string.IsNullOrWhiteSpace(_themeFolder)) if(string.IsNullOrWhiteSpace(_themeFolder))
{ {
var exeRawFolderUri = System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().CodeBase);
if(exeRawFolderUri == null)
string rawThemeFolder = _configData.ThemeFolder;
if(string.IsNullOrWhiteSpace(rawThemeFolder))
{ {
return string.Empty; // will end up as an error as themes now aren't found.
// not specified, assume local theme folder.
var exeRawFolderUri = System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().CodeBase);
if(exeRawFolderUri == null)
{
return string.Empty; // will end up as an error as themes now aren't found.
}

var exeFolder = new Uri(exeRawFolderUri).LocalPath;
rawThemeFolder = Path.Combine(exeFolder, "Themes");
} }
var exeFolder = new Uri(exeRawFolderUri).LocalPath;
_themeFolder = Path.Combine(Path.Combine(exeFolder, "Themes"), this.ThemeName);
else
{
rawThemeFolder = Utils.MakeAbsolutePath(_configFileSourcePath, (string)_configData.ThemeFolder) ?? ".";
}
_themeFolder = Path.Combine(rawThemeFolder, this.ThemeName);
} }
return _themeFolder; return _themeFolder;
} }


+ 2
- 2
src/DocNet/Properties/AssemblyInfo.cs View File

@@ -32,5 +32,5 @@ using System.Runtime.InteropServices;
// You can specify all the values or you can default the Build and Revision Numbers // You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below: // by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")] // [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("0.16.3.0")]
[assembly: AssemblyFileVersion("0.16.3")]
[assembly: AssemblyVersion("0.16.4.0")]
[assembly: AssemblyFileVersion("0.16.4")]

Loading…
Cancel
Save