Fix Sha1.GetHashCode

Fix Sha1.GetHashCode

--- src/SourceCode.Chasm/Sha1Comparer.cs
+++ src/SourceCode.Chasm/Sha1Comparer.cs
@@ -69,7 +69,18 @@

             [MethodImpl(MethodImplOptions.AggressiveInlining)]
             public override int GetHashCode(Sha1 obj)
-                => (int)obj.Blit0;
+            {
+                var h = 11L;
+
+                unchecked
+                {
+                    h = h * 7 + (long)obj.Blit0;
+                    h = h * 7 + (long)obj.Blit1;
+                    h = h * 7 + obj.Blit2;
+                }
+
+                return (int)h;
+            }
         }

         #endregion


Bumped version number to 14.6

Bumped version number to 14.6

--- src/Spark/Properties/AssemblyInfo.cs
+++ src/Spark/Properties/AssemblyInfo.cs
@@ -31,5 +31,5 @@
 //
 // You can specify all the values or you can default the Revision and Build Numbers
 // by using the '*' as shown below:
-[assembly: AssemblyVersion("14.5.0.0")]
+[assembly: AssemblyVersion("14.6.0.0")]


Adding xml doc comments to 'TextContext'

--- src/Text.Scanning/src/TextContext.cs
+++ src/Text.Scanning/src/TextContext.cs
@@ -1,10 +1,14 @@
 namespace Text.Scanning
 {
+    /// Represents an immutable implementation of the <see cref="ITextContext" /> interface
     public struct TextContext : ITextContext
     {
         private readonly int offset;

-        public TextContext(int offset) : this()
+        /// Initializes a new instance of the <see cref="TextContext" /> struct with a specified offset.
+        /// <param name="offset">The position, relative to the beginning of the data source.</param>
+        public TextContext(int offset)
+            : this()
         {
             this.offset = offset;
         }
@@ -14,8 +18,8 @@
         {
             get
             {
-                return offset;
+                return this.offset;
             }
         }
     }
-}
+}


Whoops, committed the wrong file! Revert "Fixes U4-11584 RelatedLinks2 throws exception with null value in Link field"

This reverts commit 612138f0e18a21d0f58f44a83eb7849732dc1ed3.

--- src/Umbraco.Core/ObjectExtensions.cs
+++ src/Umbraco.Core/ObjectExtensions.cs
@@ -73,9 +73,6 @@
         /// <returns>The <see cref="Attempt{T}"/></returns>
         public static Attempt<T> TryConvertTo<T>(this object input)
         {
-            if(input == null)
-                return Attempt<T>.Fail();
-
             var result = TryConvertTo(input, typeof(T));

             if (result.Success)


Adding the possibility to ignore both Id and VanityId when mapping object properties

--- CmsEngine/Extensions/ObjectExtensions.cs
+++ CmsEngine/Extensions/ObjectExtensions.cs
@@ -1,13 +1,22 @@
-using System.Linq;
+using CmsEngine.Attributes;
+using System;
+using System.Linq;

 namespace CmsEngine.Extensions
 {
     public static class ObjectExtensions
     {
-        public static object MapTo(this object source, object target)
+        public static object MapTo(this object source, object target, bool ignoreId = false)
         {
-            foreach (var sourceProp in source.GetType().GetProperties())
+            var sourceProperties = source.GetType().GetProperties();
+
+            foreach (var sourceProp in sourceProperties)
             {
+                if (ignoreId == true && (sourceProp.Name == "Id" || sourceProp.Name == "VanityId"))
+                {
+                    continue;
+                }
+
                 var targetProp = target.GetType().GetProperties().Where(p => p.Name == sourceProp.Name).FirstOrDefault();
                 if (targetProp != null && targetProp.CanWrite && targetProp.GetSetMethod() != null && targetProp.GetType().Name == sourceProp.GetType().Name)
                 {


Fixed missing path in code generator.

Fixed missing path in code generator.

--- CodeGenerator/CodeGenerator/FieldCode.cs
+++ CodeGenerator/CodeGenerator/FieldCode.cs
@@ -40,9 +40,9 @@
 			if (f.OptionCustomType != null) {
 				switch (f.OptionCustomType) {
 				case "DateTime":
-					return "new DateTime((long)ReadUInt64 (" + stream + "))";
+					return "new DateTime((long)ProtocolParser.ReadUInt64 (" + stream + "))";
 				case "TimeSpan":
-					return "new TimeSpan((long)ReadUInt64 (" + stream + "))";
+					return "new TimeSpan((long)ProtocolParser.ReadUInt64 (" + stream + "))";
 				default:
 					Field tmp = new Field ();
 					tmp.ProtoType = f.ProtoType;
@@ -188,7 +188,7 @@
 				switch (f.OptionCustomType) {
 				case "DateTime":
 				case "TimeSpan":
-					return "WriteUInt64 (" + stream + ", (ulong)" + instance + ".Ticks);\n";
+					return "ProtocolParser.WriteUInt64 (" + stream + ", (ulong)" + instance + ".Ticks);\n";
 				default:
 					return f.OptionCustomType + ".Write(" + stream + ", " + instance + ");\n";
 				}


Fixes issue with setting default column values for fields of type MultiChoice

--- Commands/Lists/SetDefaultColumnValues.cs
+++ Commands/Lists/SetDefaultColumnValues.cs
@@ -76,7 +76,7 @@
                     if (field != null)
                     {
                         IDefaultColumnValue defaultColumnValue = null;
-                        if (field.TypeAsString == "Text" || field.TypeAsString == "Choice")
+                        if (field.TypeAsString == "Text" || field.TypeAsString == "Choice" ||field.TypeAsString == "MultiChoice")
                         {
                             var values = string.Join(";", Value);
                             defaultColumnValue = new DefaultColumnTextValue()


Simplifies logger calls to proxy all calls to a single method of it's type

--- src/Umbraco.Core/Logging/Logger.cs
+++ src/Umbraco.Core/Logging/Logger.cs
@@ -176,22 +176,19 @@
         /// <inheritdoc/>
         public void Warn(Type reporting, string format)
         {
-            var logger = Log.Logger;
-            logger?.Warning(format);
+            Warn(reporting, null, format);
         }

         /// <inheritdoc/>
         public void Warn(Type reporting, string messageTemplate, params object[] propertyValues)
         {
-            var logger = Log.Logger;
-            logger?.ForContext(reporting).Warning(messageTemplate, propertyValues);
+            Warn(reporting, null, messageTemplate, propertyValues);
         }

         /// <inheritdoc/>
         public void Warn(Type reporting, Exception exception, string message)
         {
-            var logger = Log.Logger;
-            logger?.ForContext(reporting).Warning(message, exception);
+            Warn(reporting, exception, message, Array.Empty<object>());
         }

         /// <inheritdoc/>
@@ -204,8 +201,7 @@
         /// <inheritdoc/>
         public void Info(Type reporting, string message)
         {
-            var logger = Log.Logger;
-            logger?.ForContext(reporting).Information(message);
+            Info(reporting, message, Array.Empty<object>());
         }

         /// <inheritdoc/>
@@ -218,8 +214,7 @@
         /// <inheritdoc/>
         public void Debug(Type reporting, string message)
         {
-            var logger = Log.Logger;
-            logger?.ForContext(reporting).Debug(message);
+            Debug(reporting, message, Array.Empty<object>());
         }

         /// <inheritdoc/>
@@ -232,8 +227,7 @@
         /// <inheritdoc/>
         public void Verbose(Type reporting, string message)
         {
-            var logger = Log.Logger;
-            logger?.ForContext(reporting).Verbose(message);
+            Verbose(reporting, message, Array.Empty<object>());
         }

         /// <inheritdoc/>


Worked around a possible crash in design mode caused by a Visual Studio bug.

Signed-off-by: Dimitar Dobrev <ca751a5c976abad79158718440750fc638d19ebc@yahoo.com>

--- src/Vlc.DotNet.Forms/VlcControl.cs
+++ src/Vlc.DotNet.Forms/VlcControl.cs
@@ -29,7 +29,7 @@

         public void EndInit()
         {
-            if (DesignMode || myVlcMediaPlayer != null)
+            if (IsInDesignMode() || myVlcMediaPlayer != null)
                 return;
             if (VlcLibDirectory == null && (VlcLibDirectory = OnVlcLibDirectoryNeeded()) == null)
             {
@@ -38,6 +38,12 @@
             myVlcMediaPlayer = new VlcMediaPlayer(VlcLibDirectory);
             myVlcMediaPlayer.VideoHostControlHandle = Handle;
             RegisterEvents();
+        }
+
+        // work around http://stackoverflow.com/questions/34664/designmode-with-controls/708594
+        private static bool IsInDesignMode()
+        {
+            return System.Reflection.Assembly.GetExecutingAssembly().Location.Contains("VisualStudio");
         }

         public event EventHandler<VlcLibDirectoryNeededEventArgs> VlcLibDirectoryNeeded;


Fix Leave button in lobby being off to the right.

--- Content.Client/UserInterface/LobbyGui.cs
+++ Content.Client/UserInterface/LobbyGui.cs
@@ -70,7 +70,8 @@
             {
                 SizeFlagsHorizontal = SizeFlags.ShrinkEnd,
                 Text = localization.GetString("Leave"),
-                StyleClasses = {NanoStyle.StyleClassButtonBig}
+                StyleClasses = {NanoStyle.StyleClassButtonBig},
+                GrowHorizontal = GrowDirection.Begin
             });

             LeaveButton.SetAnchorAndMarginPreset(LayoutPreset.TopRight);


Update to include report.log directly into crash-report

--- Raccoon/Core/Game.cs
+++ Raccoon/Core/Game.cs
@@ -107,6 +107,11 @@
                         e = e.InnerException;
                         logWriter.WriteLine($"{System.DateTime.Now.ToString()}  InnerException: {e.Message}\n{e.StackTrace}\n");
                     }
+
+                    // include report.log
+                    System.Diagnostics.Debug.Flush();
+                    logWriter.WriteLine("\n\nreport.log\n-------------\n");
+                    logWriter.WriteLine(File.ReadAllText(Debug.LogFileName));
                 }

                 switch (System.Environment.OSVersion.Platform) {


Document that using the HttpClient parameter won't work for some options

--- Refit/RestService.cs
+++ Refit/RestService.cs
@@ -6,6 +6,8 @@
 {
     public static class RestService
     {
+        const string RefitCreatedClient = "RefitClient";
+
         static readonly ConcurrentDictionary<Type, Type> TypeMapping = new ConcurrentDictionary<Type, Type>();

         public static T For<T>(HttpClient client, IRequestBuilder<T> builder)
@@ -60,8 +62,7 @@
             return For(refitInterfaceType, client, settings);
         }

-        public static object For(Type refitInterfaceType, string hostUrl) => For(refitInterfaceType, hostUrl, null);
-
+        public static object For(Type refitInterfaceType, string hostUrl) => For(refitInterfaceType, hostUrl, null);

         public static HttpClient CreateHttpClient(string hostUrl, RefitSettings settings)
         {


Use correct types for LikeUserIDs and LikeUsernames

--- Curse.NET/SocketModel/MessageResponse.cs
+++ Curse.NET/SocketModel/MessageResponse.cs
@@ -31,8 +31,8 @@
 		public int EditedUserID { get; set; }
 		public object EditedUsername { get; set; }
 		public int LikeCount { get; set; }
-		public object[] LikeUserIDs { get; set; }
-		public object[] LikeUsernames { get; set; }
+		public int[] LikeUserIDs { get; set; }
+		public string[] LikeUsernames { get; set; }
 		public object[] ContentTags { get; set; }
 		public object[] Attachments { get; set; }
 		public int NotificationType { get; set; }


fix build error

fix build error

--- RopeTest/RunTests.cs
+++ RopeTest/RunTests.cs
@@ -8,7 +8,7 @@
 {
     public abstract class RunTests
     {
-        public abstract Structure { get; set; }
+

     }
 }


Refactor for RaceType to DerbyType

Refactor for RaceType to DerbyType

--- Derby/ViewModels/CompetitionViewModel.cs
+++ Derby/ViewModels/CompetitionViewModel.cs
@@ -1,5 +1,6 @@
 using System;
 using System.Collections.Generic;
+using System.Collections.ObjectModel;
 using System.ComponentModel.DataAnnotations;
 using System.Linq;
 using System.Web;
@@ -17,7 +18,7 @@

         [Required]
         [Display(Name = "Race Type")]
-        public RaceType RaceType { get; set; }
+        public DerbyType RaceType { get; set; }

         [Display(Name = "Created Date")]
         public DateTime CreatedDate { get; set; }
@@ -37,6 +38,7 @@

         public bool Completed { get; set; }

+        public ICollection<Scout> Scouts { get; set; }
         public List<RacerViewModel> Racers { get; set; }
         public List<Den> Dens { get; set; }

@@ -54,6 +56,7 @@
             LaneCount = competition.LaneCount;
             CreatedById = competition.CreatedById;
             Completed = competition.Completed;
+            Scouts = new List<Scout>();
             Racers = new List<RacerViewModel>();
             Dens = new List<Den>();
             Races = new List<Race>();


Fix error when loading settings with missing members

--- DesktopWidgets/Helpers/SettingsHelper.cs
+++ DesktopWidgets/Helpers/SettingsHelper.cs
@@ -20,13 +20,15 @@
         public static readonly JsonSerializerSettings JsonSerializerSettings = new JsonSerializerSettings
         {
             TypeNameHandling = TypeNameHandling.Auto,
-            ObjectCreationHandling = ObjectCreationHandling.Replace
+            ObjectCreationHandling = ObjectCreationHandling.Replace,
+            MissingMemberHandling = MissingMemberHandling.Ignore
         };

         public static readonly JsonSerializerSettings JsonSerializerSettingsAllTypeHandling = new JsonSerializerSettings
         {
             TypeNameHandling = TypeNameHandling.All,
-            ObjectCreationHandling = ObjectCreationHandling.Replace
+            ObjectCreationHandling = ObjectCreationHandling.Replace,
+            MissingMemberHandling = MissingMemberHandling.Ignore
         };

         public static object CloneObject(object obj)


FirstPropertyParser creates ParseObject, so extraneous object isn't created for references.

--- JSON/JsonParser.cs
+++ JSON/JsonParser.cs
@@ -121,11 +121,15 @@
         {
             ExpectSymbol("{");

-            ParseObject obj = valueFactory.CreateObject();
-
-            if (!IsSymbol("}"))
-            {
-                PropertyParser propertyParser = new FirstPropertyParser(this, obj);
+            ParseObject obj;
+
+            if (IsSymbol("}"))
+            {
+                obj = valueFactory.CreateObject();
+            }
+            else
+            {
+                PropertyParser propertyParser = new FirstPropertyParser(this);

                 do
                 {
@@ -166,10 +170,9 @@

             public PropertyParser NextPropertyParser { get; protected set; }

-            protected PropertyParser(JsonParser parser, ParseObject parseObject)
+            protected PropertyParser(JsonParser parser)
             {
                 Parser = parser;
-                ParseObject = parseObject;
             }

             /// <summary>
@@ -181,30 +184,32 @@

         private class FirstPropertyParser : PropertyParser
         {
-            public FirstPropertyParser(JsonParser parser, ParseObject parseObject)
-                : base(parser, parseObject)
+            public FirstPropertyParser(JsonParser parser)
+                : base(parser)
             { }

             public override void ParsePropertyValue(string name)
             {
-                switch (name)
-                {
-                    case "_ref":
-                        ParseObject = Parser.ReferenceObject();
-                        NextPropertyParser = new IgnorePropertyParser(Parser, ParseObject);
-                        return; // Don't add reference to objectReferences
-
-                    case "_type":
-                        if (Parser.SetObjectType(ParseObject))
-                            ReturnImmediately = true;   // Object was pre-built
-                        break;
-
-                    default:
-                        NextPropertyParser = new RegularPropertyParser(Parser, ParseObject);
-                        NextPropertyParser.ParsePropertyValue(name);
-                        break;
+                if (name == "_ref")
+                {
+                    ParseObject = Parser.ReferenceObject();
+                    NextPropertyParser = new IgnorePropertyParser(Parser, ParseObject);
+                    return;
                 }

+                ParseObject = Parser.valueFactory.CreateObject();
+
+                if (name == "_type")
+                {
+                    if (Parser.SetObjectType(ParseObject))
+                        ReturnImmediately = true; // Object was pre-built
+                }
+                else
+                {
+                    NextPropertyParser = new RegularPropertyParser(Parser, ParseObject);
+                    NextPropertyParser.ParsePropertyValue(name);
+                }
+
                 Parser.objectReferences.Add(ParseObject);
             }
         }
@@ -212,9 +217,10 @@
         private class IgnorePropertyParser : PropertyParser
         {
             public IgnorePropertyParser(JsonParser parser, ParseObject parseObject)
-                : base(parser, parseObject)
+                : base(parser)
             {
                 NextPropertyParser = this;
+                ParseObject = parseObject;
             }

             public override void ParsePropertyValue(string name) { }
@@ -223,9 +229,10 @@
         private class RegularPropertyParser : PropertyParser
         {
             public RegularPropertyParser(JsonParser parser, ParseObject parseObject)
-                : base(parser, parseObject)
+                : base(parser)
             {
                 NextPropertyParser = this;
+                ParseObject = parseObject;
             }

             public override void ParsePropertyValue(string name)


Added method to get logged in user info.

--- JabbR/Hubs/Chat.cs
+++ JabbR/Hubs/Chat.cs
@@ -189,6 +189,15 @@
             var textTransform = new TextTransform(_repository);
             string message = textTransform.Parse(content);
             return TextTransform.TransformAndExtractUrls(message, out links);
+        }
+
+        public UserViewModel GetUserInfo()
+        {
+            string id = Caller.id;
+
+            ChatUser user = _repository.VerifyUserId(id);
+
+            return new UserViewModel(user);
         }

         public void Disconnect()


create build script after cloning repo

create build script after cloning repo

--- src/app/CandyCane/CsharpProject.cs
+++ src/app/CandyCane/CsharpProject.cs
@@ -43,6 +43,9 @@
                 Console.WriteLine("Repository cloned");
                 Console.WriteLine("Try to build the project");

+                BuildScript buildScript = new BuildScript(Helper.GetRootPath(Helper._projectName), Helper._projectName);
+                buildScript.CreateBuildScript();
+
                 BootAndBuildBat batActions = new BootAndBuildBat(Helper.GetRootPath(Helper._projectName));
                 batActions.RunBootAndBuiltBat();


updates

updates

--- SQL/DBThreadClass.cs
+++ SQL/DBThreadClass.cs
@@ -93,6 +93,14 @@

         #endregion

+        #region Events
+
+        public delegate void ConnectionErrorDelegate(String DBAccessString);
+
+        public event ConnectionErrorDelegate OnConnectionError;
+
+        #endregion
+
         #region Constructor(s)

         /// <summary>
@@ -118,7 +126,52 @@
                 {

                     if (TaskQueue.TryDequeue(out ToDo))
-                        ToDo(CurrentDBConnection);
+                    {
+
+                        if (CurrentDBConnection == null)
+                        {
+                            Reset();
+                            Connect();
+                        }
+                        else
+                        {
+                            try
+                            {
+                                CurrentDBConnection.ShowTables();
+                            }
+                            catch (Exception e)
+                            {
+                                Reset();
+                                Connect();
+                            }
+                        }
+
+                        if (CurrentDBConnection.State != ConnectionState.Open)
+                        {
+                            Reset();
+                            Connect();
+                        }
+
+                        var Retry = false;
+
+                        do
+                        {
+
+                            try
+                            {
+                                ToDo(CurrentDBConnection);
+                            }
+                            catch (Exception)
+                            {
+                                Retry = true;
+                                Reset();
+                                Connect();
+                            }
+
+                        }
+                        while (Retry == true);
+
+                    }

                     else
                         lock (LockObject) {
@@ -135,7 +188,7 @@

         }

-        #endregion
+        #endregion<<<<<

         #region (private) Connect()
@@ -146,8 +199,16 @@
             if (CurrentDBConnection == null || CurrentDBConnection.State == ConnectionState.Closed)
                 if (DBAccessString != null)
                 {
-                    CurrentDBConnection = DBConnectionDelegate(DBAccessString);
-                    CurrentDBConnection.Open();
+                    try
+                    {
+                        CurrentDBConnection = DBConnectionDelegate(DBAccessString);
+                        CurrentDBConnection.Open();
+                    }
+                    catch (Exception e)
+                    {
+                        if (OnConnectionError != null)
+                            OnConnectionError(DBAccessString);
+                    }
                 }

             return CurrentDBConnection;
@@ -181,7 +242,7 @@
                 }

                 CurrentDBConnection = null;
-                DBAccessString      = null;
+                //DBAccessString      = null;

                 return true;


git-svn-id: 21cdf44b51306c1f0753fc51e774ecf5fc1851ba@632 a61f9e97-bd4c-0410-8c65-85b29eaa70ff

--- Dorian/Examples/Tester_Graphics/Form1.cs
+++ Dorian/Examples/Tester_Graphics/Form1.cs
@@ -179,7 +179,7 @@
 				_dev = _gfx.CreateDeviceWindow("Test", settings);
 				_dev.SetupTest();

-				_dev2 = _dev.CreateSwapChain("TestSwap", new GorgonSwapChainSettings(this.panelDX)
+				_dev2 = _dev.CreateSwapChain("TestSwap", new GorgonSwapChainSettings(form2)
 															{
 																DepthStencilFormat = GorgonBufferFormat.D16_UIntNormal,
 																MSAAQualityLevel = (quality != null ? new GorgonMSAAQualityLevel(GorgonMSAALevel.NonMasked, quality.Value) : new GorgonMSAAQualityLevel(GorgonMSAALevel.None, 0))


Fix: ProjectionInfo.GetParameter was throwing a FormatException if the ESRI string contained a parameter name that was longer than but began with the name of the parameter being gotten.

--- DotSpatial.Projections/ProjectionInfo.cs
+++ DotSpatial.Projections/ProjectionInfo.cs
@@ -905,7 +905,7 @@
                 return null;

             double? result = null;
-            int iStart = esriString.IndexOf(@"PARAMETER[""" + name, StringComparison.InvariantCultureIgnoreCase);
+            int iStart = esriString.IndexOf(@"PARAMETER[""" + name + "\"", StringComparison.InvariantCultureIgnoreCase);
             if (iStart >= 0)
             {
                 iStart += 13 + name.Length;


Fixed Group Scale Issue

Fixed Group Scale Issue

--- Editor/GroupObjects.cs
+++ Editor/GroupObjects.cs
@@ -49,7 +49,8 @@
                     groupPosition = commonParent.InverseTransformPoint(groupPosition);
             }
             newGroup.transform.localPosition = groupPosition;
-            foreach (GameObject go in Selection.gameObjects)
+            newGroup.transform.localScale = Vector3.one;
+			foreach (GameObject go in Selection.gameObjects)
                 Undo.SetTransformParent(go.transform, newGroup.transform, "GroupObjects");
         }
         Selection.activeGameObject = newGroup;


AutoTile Fallback #ADD: When resolving indices for a tile that wasn't an AutoTile when it was serialized, but is an AutoTile now, its differing base index will be used to derive the appropriate connectivity state.

--- DualityPlugins/Tilemaps/Tilemaps/Tile.cs
+++ DualityPlugins/Tilemaps/Tilemaps/Tile.cs
@@ -137,6 +137,16 @@
 			// different Tileset configs.
 			else
 			{
+				// If there is no connectivity info and a non-matching base index, this tile
+				// was likely painted before it was configured to be an AutoTile. In that case,
+				// derive the appropriate connectivity from the specs and adjust the base index
+				// to match.
+				if (this.BaseIndex != autoTile.BaseTileIndex && this.AutoTileCon == TileConnection.None)
+				{
+					this.AutoTileCon = autoTile.TileInfo[this.BaseIndex].Neighbours;
+					this.BaseIndex = autoTile.BaseTileIndex;
+				}
+
 				int targetIndex = autoTile.StateToTile[(int)this.AutoTileCon];

 				// If the AutoTile connectivity state already matches the one we'd get with the default


Release v1.8.4

Release v1.8.4

--- LSLib/LS/Common.cs
+++ LSLib/LS/Common.cs
@@ -10,7 +10,7 @@
     {
         public const int MajorVersion = 1;
         public const int MinorVersion = 8;
-        public const int PatchVersion = 3;
+        public const int PatchVersion = 4;

         /// <summary>
         /// Returns the version number of the LSLib library


Remove the artwork only if the song is removed from the library, not if it is disposed on application shutdown

--- Espera/Espera.Core/Management/Library.cs
+++ Espera/Espera.Core/Management/Library.cs
@@ -712,15 +712,8 @@
         /// <param name="songList">The songs to dispose.</param>
         private static void DisposeSongs(IEnumerable<Song> songList)
         {
-            IEnumerable<Song> enumerable = songList.ToList();
-
-            foreach (string key in enumerable.Cast<LocalSong>().Select(s => s.ArtworkKey.FirstAsync().Wait()).Where(key => key != null))
-            {
-                BlobCache.LocalMachine.Invalidate(key);
-            }
-
             // If the condition is removed, every file that has been added to the library will be deleted...
-            foreach (LocalSong song in enumerable.Where(song => song.HasToCache && song.IsCached))
+            foreach (LocalSong song in songList.Where(song => song.HasToCache && song.IsCached))
             {
                 try
                 {
@@ -920,13 +913,20 @@
             if (songList == null)
                 Throw.ArgumentNullException(() => songList);

-            DisposeSongs(songList);
-
-            this.playlists.ForEach(playlist => this.RemoveFromPlaylist(playlist, songList));
+            List<Song> enumerable = songList.ToList();
+
+            foreach (LocalSong song in enumerable)
+            {
+                BlobCache.LocalMachine.Invalidate(song.ArtworkKey.FirstAsync().Wait());
+            }
+
+            DisposeSongs(enumerable);
+
+            this.playlists.ForEach(playlist => this.RemoveFromPlaylist(playlist, enumerable));

             lock (this.songLock)
             {
-                foreach (Song song in songList)
+                foreach (LocalSong song in enumerable)
                 {
                     this.songs.Remove(song);
                 }


Update LoadWebImage.cs

Update LoadWebImage.cs

--- Examples/CSharp/Articles/LoadWebImage.cs
+++ Examples/CSharp/Articles/LoadWebImage.cs
@@ -9,6 +9,7 @@
     {
         public static void Main()
         {
+            //ExStart:1
             // The path to the documents directory.
             string dataDir = Aspose.Cells.Examples.Utils.GetDataDir(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
             //Define memory stream object
@@ -48,8 +49,9 @@
                 //Write the error message on the console
                 Console.WriteLine(ex.Message);
             }
+            //ExEnd:1

         }
     }
-}+}


Add additional IUserIdentity properties

Add additional IUserIdentity properties

--- ExoMail.Smtp/Interfaces/IUserIdentity.cs
+++ ExoMail.Smtp/Interfaces/IUserIdentity.cs
@@ -12,5 +12,8 @@
         string UserName { get; set; }
         string Password { get; set; }
         string EmailAddress { get; set; }
+        List<string> AliasAddresses { get; set; }
+        string FirstName { get; set; }
+        string LastName { get; set; }
     }
 }


Update version number.

Update version number.

--- FSActiveFires/Properties/AssemblyInfo.cs
+++ FSActiveFires/Properties/AssemblyInfo.cs
@@ -51,5 +51,5 @@
 // You can specify all the values or you can default the Build and Revision Numbers
 // by using the '*' as shown below:
 // [assembly: AssemblyVersion("1.0.*")]
-[assembly: AssemblyVersion("0.1.0.0")]
-[assembly: AssemblyFileVersion("0.1.0.0")]
+[assembly: AssemblyVersion("0.1.0.1")]
+[assembly: AssemblyFileVersion("0.1.0.1")]


Fixed a little ticket bug

Fixed a little ticket bug

--- Favor/Favor/Views/Profile/Profile.cshtml
+++ Favor/Favor/Views/Profile/Profile.cshtml
@@ -301,14 +301,14 @@

                                                                                @ticketForAdmin.SenderFullName
-                                                                                @ticketForAdmin.Type.ToString()
+                                                                                @ticketForAdmin.Type.ToString()
                                                                                @ticketForAdmin.Title
                                                                                @ticketForAdmin.Content
                                                                                @ticketForAdmin.TimeSent

-
+

@@ -331,14 +331,14 @@
                                                                         {

                                                                                @ticketForSender.Reciever
-                                                                                @ticketForSender.Type.ToString()
+                                                                                @ticketForSender.Type.ToString()
                                                                                @ticketForSender.Title
                                                                                @ticketForSender.Content
                                                                                @ticketForSender.TimeSent

-
+


Format test cases.

Format test cases.

--- Gu.State.Tests/EqualByTests/TestCases.cs
+++ Gu.State.Tests/EqualByTests/TestCases.cs
@@ -150,61 +150,26 @@

         public static readonly TestCaseData[] WhenNotEqualStructural =
         {
-            new TestCaseData(
-                new With<int[]>(new[] { 1, 2, 3 }),
-                new With<int[]>(new[] { 1, 2, 4 })),
-            new TestCaseData(
-                new With<int[]>(new[] { 1, 2, 3 }),
-                new With<int[]>(new[] { 0, 2, 3 })),
-            new TestCaseData(
-                new With<int[]>(new[] { 1, 2 }),
-                new With<int[]>(new[] { 1, 2, 3 })),
-            new TestCaseData(
-                new With<int[]>(new[] { 1, 2 }),
-                new With<int[]>(null)),
-            new TestCaseData(
-                new With<int[]>(new int[0]),
-                new With<int[]>(null)),
+            new TestCaseData(new With<int[]>(new[] { 1, 2, 3 }), new With<int[]>(new[] { 1, 2, 4 })),
+            new TestCaseData(new With<int[]>(new[] { 1, 2, 3 }), new With<int[]>(new[] { 0, 2, 3 })),
+            new TestCaseData(new With<int[]>(new[] { 1, 2 }), new With<int[]>(new[] { 1, 2, 3 })),
+            new TestCaseData(new With<int[]>(new[] { 1, 2 }), new With<int[]>(null)),
+            new TestCaseData(new With<int[]>(new int[0]), new With<int[]>(null)),

-            new TestCaseData(
-                new With<List<int>>(new List<int> { 1, 2, 3 }),
-                new With<List<int>>(new List<int> { 1, 2, 4 })),
-            new TestCaseData(
-                new With<List<int>>(new List<int> { 1, 2, 3 }),
-                new With<List<int>>(new List<int> { 0, 2, 3 })),
-            new TestCaseData(
-                new With<List<int>>(new List<int> { 1, 2 }),
-                new With<List<int>>(new List<int> { 1, 2, 3 })),
-            new TestCaseData(
-                new With<List<int>>(new List<int> { 1, 2 }),
-                new With<List<int>>(null)),
-            new TestCaseData(
-                new With<List<int>>(new List<int>()),
-                new With<List<int>>(null)),
+            new TestCaseData(new With<List<int>>(new List<int> { 1, 2, 3 }), new With<List<int>>(new List<int> { 1, 2, 4 })),
+            new TestCaseData(new With<List<int>>(new List<int> { 1, 2, 3 }), new With<List<int>>(new List<int> { 0, 2, 3 })),
+            new TestCaseData(new With<List<int>>(new List<int> { 1, 2 }), new With<List<int>>(new List<int> { 1, 2, 3 })),
+            new TestCaseData(new With<List<int>>(new List<int> { 1, 2 }), new With<List<int>>(null)),
+            new TestCaseData(new With<List<int>>(new List<int>()), new With<List<int>>(null)),

-            new TestCaseData(
-                new With<IReadOnlyList<int>>(new[] { 1, 2, 3 }),
-                new With<IReadOnlyList<int>>(new[] { 1, 2, 4 })),
-            new TestCaseData(
-                new With<IReadOnlyList<int>>(new[] { 1, 2, 3 }),
-                new With<IReadOnlyList<int>>(new[] { 0, 2, 3 })),
-            new TestCaseData(
-                new With<IReadOnlyList<int>>(new[] { 1, 2 }),
-                new With<IReadOnlyList<int>>(new[] { 1, 2, 3 })),
-            new TestCaseData(
-                new With<IReadOnlyList<int>>(new[] { 1, 2 }),
-                new With<IReadOnlyList<int>>(null)),
-            new TestCaseData(
-                new With<IReadOnlyList<int>>(new int[0]),
-                new With<IReadOnlyList<int>>(null)),
+            new TestCaseData(new With<IReadOnlyList<int>>(new[] { 1, 2, 3 }), new With<IReadOnlyList<int>>(new[] { 1, 2, 4 })),
+            new TestCaseData(new With<IReadOnlyList<int>>(new[] { 1, 2, 3 }), new With<IReadOnlyList<int>>(new[] { 0, 2, 3 })),
+            new TestCaseData(new With<IReadOnlyList<int>>(new[] { 1, 2 }), new With<IReadOnlyList<int>>(new[] { 1, 2, 3 })),
+            new TestCaseData(new With<IReadOnlyList<int>>(new[] { 1, 2 }), new With<IReadOnlyList<int>>(null)),
+            new TestCaseData(new With<IReadOnlyList<int>>(new int[0]), new With<IReadOnlyList<int>>(null)),

-            new TestCaseData(
-                new With<BaseClass>(new Derived1 { BaseValue = 1, Derived1Value = 2 }),
-                new With<BaseClass>(new Derived1 { BaseValue = 1, Derived1Value = -2 })),
-            new TestCaseData(
-                new With<BaseClass>(new Derived1()),
-                new With<BaseClass>(new Derived2())),
-
+            new TestCaseData(new With<BaseClass>(new Derived1 { BaseValue = 1, Derived1Value = 2 }), new With<BaseClass>(new Derived1 { BaseValue = 1, Derived1Value = -2 })),
+            new TestCaseData(new With<BaseClass>(new Derived1()), new With<BaseClass>(new Derived2())),
         };
     }
 }


Minor refactorings to enable it to perform full enumeration of all formats supported.

Easiest way to run it is simply: SimpleEnumeration > output.txt && notepad output.txt

--- samples/Direct3D10/SimpleEnumeration/Program.cs
+++ samples/Direct3D10/SimpleEnumeration/Program.cs
@@ -32,7 +32,6 @@

         private static void PrintDeviceInformation(Adapter adapter) {
             using (var device = new Device(adapter, DriverType.Hardware, DeviceCreationFlags.None)) {
-                PrintSupportedQualityLevels(device);
                 PrintSupportedFormats(device);
             }
         }
@@ -43,20 +42,23 @@
                 Console.WriteLine("        Format: {0}", format);
                 var formatSupport = device.CheckFormatSupport((Format)format);
                 Console.WriteLine("            Format support: {0}", formatSupport);
+                PrintSupportedQualityLevels(device, (Format) format);
             }
         }

-        private static void PrintSupportedQualityLevels(Device device) {
-            Console.WriteLine("    Multi-Sample Support:");
+        private static void PrintSupportedQualityLevels(Device device, Format format) {
             for (var sampleCount = 1; sampleCount <= 32; sampleCount *= 2) {
-                var qualityLevels = device.CheckMultisampleQualityLevels(Format.R8G8B8A8_UNorm, sampleCount);
-                Console.WriteLine("        Sample Count: {0}", sampleCount);
+                var qualityLevels = device.CheckMultisampleQualityLevels(format, sampleCount);
+                Console.WriteLine("            Sample Count: {0}", sampleCount);

                 if (qualityLevels != 0)
-                    Console.WriteLine("            Max Quality Level: {0}", qualityLevels);
+                    Console.WriteLine("                Max Quality Level: {0}", qualityLevels);
                 else {
-                    Console.WriteLine("            Not supported");
+                    Console.WriteLine("                Not supported");
                 }
+
+                if (qualityLevels == 0)
+                    break;
             }
         }

@@ -71,7 +73,9 @@
                         Console.WriteLine("        {0}: {1}", ParseName(descProperty.Name), descProperty.GetValue(output.Description, null));
                     }

-                    PrintDisplayModes(output, Format.R8G8B8A8_UNorm);
+                    foreach (var format in Enum.GetValues(typeof(Format))) {
+                        PrintDisplayModes(output, (Format)format);
+                    }
                 }
             }
         }
@@ -80,6 +84,9 @@
             Console.WriteLine("        Display modes for format: {0}", format);

             var displayModes = output.GetDisplayModeList(format, 0);
+
+            if(displayModes == null)
+                return;

             foreach (var displayMode in displayModes) {
                 foreach (var descProperty in displayMode.GetType().GetProperties()) {


Fixed naming issue

Fixed naming issue

--- FEClient/Forms/Logs.cs
+++ FEClient/Forms/Logs.cs
@@ -7,7 +7,7 @@
 {
     public partial class Logs : Form
     {
-        private readonly DirectoryInfo _sentLogpath = new DirectoryInfo(Application.UserAppDataPath + @"\logs\sent\");
+        private readonly DirectoryInfo _sentLogPath = new DirectoryInfo(Application.UserAppDataPath + @"\logs\sent\");
         private readonly DirectoryInfo _receivedLogPath = new DirectoryInfo(Application.UserAppDataPath + @"\logs\received\");
         public Logs()
         {
@@ -19,9 +19,9 @@

         private void Logs_Load(object sender, EventArgs e)
         {
-            if (_sentLogpath.Exists)
+            if (_sentLogPath.Exists)
             {
-                foreach (var file in _sentLogpath.GetFiles())
+                foreach (var file in _sentLogPath.GetFiles())
                 {
                     var i = new ListViewItem(file.Name) { ImageIndex = 0 };
                     sentListView.Items.Add(i);
@@ -59,7 +59,7 @@

         private void sentListView_DoubleClick(object sender, EventArgs e)
         {
-            var logPath = _sentLogpath;
+            var logPath = _sentLogPath;

             Show_Log(sender, logPath);
         }


Added some fields and a Stop method to Plugin

--- FameBot/Core/Plugin.cs
+++ FameBot/Core/Plugin.cs
@@ -7,6 +7,7 @@
 using Lib_K_Relay;
 using System.Diagnostics;
 using FameBot.Data.Enums;
+using FameBot.Data.Models;

 namespace FameBot.Core
 {
@@ -38,10 +39,13 @@
         #endregion

         private IntPtr flashPtr;
-
+        private bool followTarget = false;
+        private Queue<Target> targets;

         public void Initialize(Proxy proxy)
         {
+            targets = new Queue<Target>();
+
             Process[] processes = Process.GetProcessesByName("flash");
             if (processes.Length == 1)
             {
@@ -55,6 +59,11 @@
                 Console.WriteLine("[FameBot] Couldn't find any instances of flash player. Use the /activate command when you have opened flash.");
                 Console.WriteLine("[FameBot] FameBot will only detect instances of flash player which are called \"flash.exe\"");
             }
+
+            proxy.ClientConnected += (client) =>
+            {
+                Stop();
+            };
         }

         private void GuiEventCallback(GuiEvent evt)
@@ -65,9 +74,15 @@

                     break;
                 case GuiEvent.StopBot:
-
+                    Stop();
                     break;
             }
         }
+
+        private void Stop()
+        {
+            followTarget = false;
+            targets.Clear();
+        }
     }
 }


Fix a bug that enables to send any 'Reserved value' close status code

--- websocket-sharp/WebSocket.cs
+++ websocket-sharp/WebSocket.cs
@@ -666,7 +666,7 @@
       _logger.Trace ("Start closing the connection.");

       e.WasClean = closeHandshake (
-        WebSocketFrame.CreateCloseFrame (e.PayloadData, _client).ToByteArray (),
+        send ? WebSocketFrame.CreateCloseFrame (e.PayloadData, _client).ToByteArray () : null,
         wait ? _waitTime : TimeSpan.Zero,
         _client ? (Action) releaseClientResources : releaseServerResources);


Fixed constructor bug (Ram1(), not Ram2()).

--- Sega/Mappers/Ram1.cs
+++ Sega/Mappers/Ram1.cs
@@ -72,7 +72,7 @@
 		/// <summary>
 		/// Creates an instance of the <see cref="Ram1"/> mapper.
 		/// </summary>
-		public Ram2() {
+		public Ram1() {
 			this.memory = new byte[0x400];
 		}


Non-zero value makes more sense

Non-zero value makes more sense

If this defaults to 0, effectively it makes the element mandatory.

--- ServiceDescriptor.cs
+++ ServiceDescriptor.cs
@@ -501,7 +501,7 @@
         {
             get
             {
-                return SingleTimeSpanElement(dom, "resetfailure", TimeSpan.Zero);
+                return SingleTimeSpanElement(dom, "resetfailure", TimeSpan.FromDays(1));
             }
         }


began implementing Currency class

began implementing Currency class

--- Services/Currency.cs
+++ Services/Currency.cs
@@ -7,7 +7,7 @@
 using System.Web.Mvc;

 namespace Nwazet.Commerce.Services {
-    public static class Currency {
+    public class Currency {
         /// <summary>
         /// This is a list of iso4217 codes, updated on 2017/03/22 (March 22, 2017).
         /// For the list: http://www.xe.com/iso4217.php
@@ -203,6 +203,180 @@

         public static Dictionary<string, string> CurrencyCodes { get { return _currencyCodes.Value; } }

+        public static readonly Dictionary<string, Currency> Currencies = new Dictionary<string, Currency>(InitializeIsoCurrencies());
+
+        private static readonly string CurrencySign = CultureInfo.InvariantCulture.NumberFormat.CurrencySymbol;
+
+        private static IDictionary<string, Currency> InitializeIsoCurrencies() {
+            return new Dictionary<string, Currency> {
+                { "AED", new Currency("AED", "United Arab Emirates dirham", "د.إ") },
+                { "AFN", new Currency("AFN", "Afghan afghani", "؋") },
+                { "ALL", new Currency("ALL", "Albanian lek", "Lek") },
+                { "AMD", new Currency("AMD", "Armenian dram", "֏") },
+                { "ANG", new Currency("ANG", "Netherlands Antillean guilder", "ƒ") },
+                { "AOA", new Currency("AOA", "Angolan kwanza", "Kz") },
+                { "ARS", new Currency("ARS", "Argentine peso", "$") },
+                { "AUD", new Currency("AUD", "Australian dollar", "$") },
+                { "AWG", new Currency("AWG", "Aruban florin", "ƒ") },
+                { "AZN", new Currency("AZN", "Azerbaijani manat", "ман") },
+                { "BAM", new Currency("BAM", "Bosnia and Herzegovina convertible mark", "KM") },
+                { "BBD", new Currency("BBD", "Barbados dollar", "$") },
+                { "BDT", new Currency("BDT", "Bangladeshi taka", "৳") },
+                { "BGN", new Currency("BGN", "Bulgarian lev", "лв.") },
+                { "BHD", new Currency("BHD", "Bahraini dinar", "د.ب.") },
+                { "BIF", new Currency("BIF", "Burundian franc", "FBu") },
+                { "BMD", new Currency("BMD", "Bermudian dollar", "$") },
+                { "BND", new Currency("BND", "Brunei dollar", "$") },
+                { "BOB", new Currency("BOB", "Boliviano", "Bs.") },
+                { "BOV", new Currency("BOV", "Bolivian Mvdol (funds code)", Currency.CurrencySign) },
+                { "BRL", new Currency("BRL", "Brazilian real", "R$") },
+                { "BSD", new Currency("BSD", "Bahamian dollar", "$") },
+                { "BTN", new Currency("BTN", "Bhutanese ngultrum", "Nu.") },
+                { "BWP", new Currency("BWP", "Botswana pula", "P") },
+                { "BYN", new Currency("BYN", "Belarusian ruble", "Br") },
+                { "BZD", new Currency("BZD", "Belize dollar", "BZ$") },
+                { "CAD", new Currency("CAD", "Canadian dollar", "$") },
+                { "CDF", new Currency("CDF", "Congolese franc", "FC") },
+                { "CHE", new Currency("CHE", "WIR Euro (complementary currency)", "CHE") },
+                { "CHF", new Currency("CHF", "Swiss franc", "CHF") },
+                { "CHW", new Currency("CHW", "WIR Franc (complementary currency)", "CHW") },
+                { "CLF", new Currency("CLF", "Unidad de Fomento (funds code)", "CLF") },
+                { "CLP", new Currency("CLP", "Chilean peso", "$") },
+                { "CNY", new Currency("CNY", "Yuan Renminbi", "¥") },
+                { "COP", new Currency("COP", "Colombian peso", "$") },
+                { "COU", new Currency("COU", "Unidad de Valor Real", Currency.CurrencySign) },
+                { "CRC", new Currency("CRC", "Costa Rican colon", "₡") },
+                { "CUC", new Currency("CUC", "Cuban convertible peso", "CUC$") },
+                { "CUP", new Currency("CUP", "Cuban peso", "$") },
+                { "CVE", new Currency("CVE", "Cape Verde escudo", "$") },
+                { "CZK", new Currency("CZK", "Czech koruna", "Kč") },
+                { "DJF", new Currency("DJF", "Djiboutian franc", "Fdj") },
+                { "DKK", new Currency("DKK", "Danish krone", "kr.") },
+                { "DOP", new Currency("DOP", "Dominican peso", "RD$") },
+                { "DZD", new Currency("DZD", "Algerian dinar", "DA") },
+                { "EGP", new Currency("EGP", "Egyptian pound", "E£") },
+                { "ERN", new Currency("ERN", "Eritrean nakfa", "ERN") },
+                { "ETB", new Currency("ETB", "Ethiopian birr", "Br") },
+                { "EUR", new Currency("EUR", "Euro", "€") },
+                { "FJD", new Currency("FJD", "Fiji dollar", "FJ$") },
+                { "FKP", new Currency("FKP", "Falkland Islands pound", "£") },
+                { "GBP", new Currency("GBP", "Pound sterling", "£") },
+                { "GEL", new Currency("GEL", "Georgian lari", "ლ") },
+                { "GHS", new Currency("GHS", "Ghanaian cedi", "GH¢") },
+                { "GIP", new Currency("GIP", "Gibraltar pound", "£") },
+                { "GMD", new Currency("GMD", "Gambian dalasi", "D") },
+                { "GNF", new Currency("GNF", "Guinean franc", "FG") },
+                { "GTQ", new Currency("GTQ", "Guatemalan quetzal", "Q") },
+                { "GYD", new Currency("GYD", "Guyanese dollar", "G$") },
+                { "HKD", new Currency("HKD", "Hong Kong dollar", "HK$") },
+                { "HNL", new Currency("HNL", "Honduran lempira", "L") },
+                { "HRK", new Currency("HRK", "Croatian kuna", "kn") },
+                { "HTG", new Currency("HTG", "Haitian gourde", "G") },
+                { "HUF", new Currency("HUF", "Hungarian forint", "Ft") },
+                { "IDR", new Currency("IDR", "Indonesian rupiah", "Rp") },
+                { "ILS", new Currency("ILS", "Israeli new shekel", "₪") },
+                { "INR", new Currency("INR", "Indian rupee", "₹") },
+                { "IQD", new Currency("IQD", "Iraqi dinar", "د.ع") },
+                { "IRR", new Currency("IRR", "Iranian rial", "ريال") },
+                { "ISK", new Currency("ISK", "Icelandic króna", "kr") },
+                { "JMD", new Currency("JMD", "Jamaican dollar", "J$") },
+                { "JOD", new Currency("JOD", "Jordanian dinar", "د.ا.") },
+                { "JPY", new Currency("JPY", "Japanese yen", "¥") },
+                { "KES", new Currency("KES", "Kenyan shilling", "KSh") },
+                { "KGS", new Currency("KGS", "Kyrgyzstani som", "сом") },
+                { "KHR", new Currency("KHR", "Cambodian riel", "៛") },
+                { "KMF", new Currency("KMF", "Comoro franc", "CF") },
+                { "KPW", new Currency("KPW", "North Korean won", "₩") },
+                { "KRW", new Currency("KRW", "South Korean won", "₩") },
+                { "KWD", new Currency("KWD", "Kuwaiti dinar", "د.ك") },
+                { "KYD", new Currency("KYD", "Cayman Islands dollar", "$") },
+                { "KZT", new Currency("KZT", "Kazakhstani tenge", "₸") },
+                { "LAK", new Currency("LAK", "Lao kip", "₭") },
+                { "LBP", new Currency("LBP", "Lebanese pound", "ل.ل") },
+                { "LKR", new Currency("LKR", "Sri Lankan rupee", "Rs") },
+                { "LRD", new Currency("LRD", "Liberian dollar", "L$") },
+                { "LSL", new Currency("LSL", "Lesotho loti", "L") },
+                { "LYD", new Currency("LYD", "Libyan dinar", "ل.د") },
+                { "MAD", new Currency("MAD", "Moroccan dirham", "د.م.") },
+                { "MDL", new Currency("MDL", "Moldovan leu", "L") },
+                { "MGA", new Currency("MGA", "Malagasy ariary", "Ar") },
+                { "MKD", new Currency("MKD", "Macedonian denar", "ден") },
+                { "MMK", new Currency("MMK", "Myanma kyat", "K") },
+                { "MNT", new Currency("MNT", "Mongolian tugrik", "₮") },
+                { "MOP", new Currency("MOP", "Macanese pataca", "MOP$") },
+                { "MRO", new Currency("MRO", "Mauritanian ouguiya", "UM") },
+                { "MUR", new Currency("MUR", "Mauritian rupee", "Rs") },
+                { "MVR", new Currency("MVR", "Maldivian rufiyaa", "Rf") },
+                { "MWK", new Currency("MWK", "Malawi kwacha", "MK") },
+                { "MXN", new Currency("MXN", "Mexican peso", "$") },
+                { "MXV", new Currency("MXV", "Mexican Unidad de Inversion (UDI) (funds code)", Currency.CurrencySign) },
+                { "MYR", new Currency("MYR", "Malaysian ringgit", "RM") },
+                { "MZN", new Currency("MZN", "Mozambican metical", "MTn") },
+                { "NAD", new Currency("NAD", "Namibian dollar", "N$") },
+                { "NGN", new Currency("NGN", "Nigerian naira", "₦") },
+                { "NIO", new Currency("NIO", "Nicaraguan córdoba oro", "C$") },
+                { "NOK", new Currency("NOK", "Norwegian krone", "kr") },
+                { "NPR", new Currency("NPR", "Nepalese rupee", "Rs") },
+                { "NZD", new Currency("NZD", "New Zealand dollar", "$") },
+                { "OMR", new Currency("OMR", "Omani rial", "ر.ع.") },
+                { "PAB", new Currency("PAB", "Panamanian balboa", "B/.") },
+                { "PEN", new Currency("PEN", "Peruvian sol", "S/.") },
+                { "PGK", new Currency("PGK", "Papua New Guinean kina", "K") },
+                { "PHP", new Currency("PHP", "Philippine peso", "₱") },
+                { "PKR", new Currency("PKR", "Pakistani rupee", "Rs") },
+                { "PLN", new Currency("PLN", "Polish złoty", "zł") },
+                { "PYG", new Currency("PYG", "Paraguayan guaraní", "₲") },
+                { "QAR", new Currency("QAR", "Qatari riyal", "ر.ق") },
+                { "RON", new Currency("RON", "Romanian new leu", "lei") },
+                { "RSD", new Currency("RSD", "Serbian dinar", "РСД") },
+                { "RUB", new Currency("RUB", "Russian rouble", "₽") },
+                { "RWF", new Currency("RWF", "Rwandan franc", "RFw") },
+                { "SAR", new Currency("SAR", "Saudi riyal", "ر.س") },
+                { "SBD", new Currency("SBD", "Solomon Islands dollar", "SI$") },
+                { "SCR", new Currency("SCR", "Seychelles rupee", "SR") },
+                { "SDG", new Currency("SDG", "Sudanese pound", "ج.س.") },
+                { "SEK", new Currency("SEK", "Swedish krona/kronor", "kr") },
+                { "SGD", new Currency("SGD", "Singapore dollar", "S$") },
+                { "SHP", new Currency("SHP", "Saint Helena pound", "£") },
+                { "SLL", new Currency("SLL", "Sierra Leonean leone", "Le") },
+                { "SOS", new Currency("SOS", "Somali shilling", "S") },
+                { "SRD", new Currency("SRD", "Surinamese dollar", "$") },
+                { "SSP", new Currency("SSP", "South Sudanese pound", "£") },
+                { "STD", new Currency("STD", "São Tomé and Príncipe dobra", "Db") },
+                { "SVC", new Currency("SVC", "El Salvador Colon", "₡") },
+                { "SYP", new Currency("SYP", "Syrian pound", "ܠ.ܣ.") },
+                { "SZL", new Currency("SZL", "Swazi lilangeni", "L") },
+                { "THB", new Currency("THB", "Thai baht", "฿") },
+                { "TJS", new Currency("TJS", "Tajikistani somoni", "смн") },
+                { "TMT", new Currency("TMT", "Turkmenistani new manat", "m") },
+                { "TND", new Currency("TND", "Tunisian dinar", "د.ت") },
+                { "TOP", new Currency("TOP", "Tongan paʻanga", "T$") },
+                { "TRY", new Currency("TRY", "Turkish lira", "₺") },
+                { "TTD", new Currency("TTD", "Trinidad and Tobago dollar", "$") },
+                { "TWD", new Currency("TWD", "New Taiwan dollar", "NT$") },
+                { "TZS", new Currency("TZS", "Tanzanian shilling", "x/y") },
+                { "UAH", new Currency("UAH", "Ukrainian hryvnia", "₴") },
+                { "UGX", new Currency("UGX", "Ugandan shilling", "USh") },
+                { "USD", new Currency("USD", "United States dollar", "$") },
+                { "USN", new Currency("USN", "United States dollar (next day) (funds code)", "$") },
+                { "UYI", new Currency("UYI", "Uruguay Peso en Unidades Indexadas (URUIURUI) (funds code)", Currency.CurrencySign) },
+                { "UYU", new Currency("UYU", "Uruguayan peso", "$") },
+                { "UZS", new Currency("UZS", "Uzbekistan sum", "лв") },
+                { "VEF", new Currency("VEF", "Venezuelan bolívar", "Bs.") },
+                { "VND", new Currency("VND", "Vietnamese dong", "₫") },
+                { "VUV", new Currency("VUV", "Vanuatu vatu", "VT") },
+                { "WST", new Currency("WST", "Samoan tala", "WS$") },
+                { "XAF", new Currency("XAF", "CFA franc BEAC", "FCFA") },
+                { "XCD", new Currency("XCD", "East caribbean dollar", "")},
+                { "XOF", new Currency("XOF", "CFA franc BCEAO", "FCFA") },
+                { "XPF", new Currency("XPF", "CFP franc", "") },
+                { "YER", new Currency("YER", "Yemeni rial", "﷼") },
+                { "ZAR", new Currency("ZAR", "South African rand", "R") },
+                { "ZMW", new Currency("ZMW", "Zambian kwacha", "ZK") },
+                { "ZWL", new Currency("ZWL", "Zimbabwean dollar", "$") }
+            };
+        }
+
         /// <summary>
         /// Given a currency code, returns a string representing the currency.
         /// </summary>
@@ -214,7 +388,8 @@
             //TODO: implement symbols from that table
             if (code == "EUR") {
                 return "€";
-            } else if (code == "USD") {
+            }
+            else if (code == "USD") {
                 return "$";
             }
             else {
@@ -252,5 +427,34 @@
             }
             return string.Empty;
         }
+
+        public string CurrencyCode { get; set; } //3-letter ISO 4217 code
+        public string CurrencyName { get; set; } //ISO 4217 currency name
+        public string Symbol { get; set; } //Symbol used for the currency
+        //Properties we use to format strings using the currency:
+        private NumberFormatInfo _numberFormatInfo;
+        private CultureInfo _cultureInfo;
+        //
+
+        /// <summary>
+        /// Creates a new instance of Currency
+        /// </summary>
+        /// <param name="currencyCode">The ISO-4217 code identifying the currency</param>
+        /// <param name="currencyName">The name of the currency</param>
+        /// <param name="symbol">The symbol to be used for the currency</param>
+        /// <param name="decimalDigits">The number of decimal places to use</param>
+        /// <param name="decimalSeparator">The string to use as the decimal separator</param>
+        /// <param name="groupSeparator">The string that separates groups of digits to the left of the decimal</param>
+        /// <param name="groupSizes">The number of digits in each group to the left of the decimal</param>
+        public Currency(string currencyCode, string currencyName, string symbol,
+            int decimalDigits = -1, string decimalSeparator = null, string groupSeparator = null, IEnumerable<int> groupSizes = null) {
+
+            CurrencyCode = currencyCode;
+            CurrencyName = currencyName;
+            Symbol = symbol;
+            //generate this Currency's NumberFormatInfo
+
+            //generate this Currency's CultureInfo
+        }
     }
 }


Use ParseEvent.Type in Emitter (follow YamlDotNet recent changes)

--- SharpYaml/Emitter.cs
+++ SharpYaml/Emitter.cs
@@ -246,61 +246,6 @@
 			}
 		}

-		private static EventType GetEventType(ParsingEvent @event)
-		{
-			if (@event is AnchorAlias)
-			{
-				return EventType.YAML_ALIAS_EVENT;
-			}
-
-			if (@event is DocumentEnd)
-			{
-				return EventType.YAML_DOCUMENT_END_EVENT;
-			}
-
-			if (@event is DocumentStart)
-			{
-				return EventType.YAML_DOCUMENT_START_EVENT;
-			}
-
-			if (@event is MappingEnd)
-			{
-				return EventType.YAML_MAPPING_END_EVENT;
-			}
-
-			if (@event is MappingStart)
-			{
-				return EventType.YAML_MAPPING_START_EVENT;
-			}
-
-			if (@event is Scalar)
-			{
-				return EventType.YAML_SCALAR_EVENT;
-			}
-
-			if (@event is SequenceEnd)
-			{
-				return EventType.YAML_SEQUENCE_END_EVENT;
-			}
-
-			if (@event is SequenceStart)
-			{
-				return EventType.YAML_SEQUENCE_START_EVENT;
-			}
-
-			if (@event is StreamEnd)
-			{
-				return EventType.YAML_STREAM_END_EVENT;
-			}
-
-			if (@event is StreamStart)
-			{
-				return EventType.YAML_STREAM_START_EVENT;
-			}
-
-			throw new ArgumentException("The specified event is of the wrong type.");
-		}
-
 		/// <summary>
 		/// Check if we need to accumulate more events before emitting.
 		///
@@ -317,7 +262,7 @@
 			}

 			int accumulate;
-			switch (GetEventType(events.Peek()))
+			switch (events.Peek().Type)
 			{
 				case EventType.YAML_DOCUMENT_START_EVENT:
 					accumulate = 1;
@@ -343,7 +288,7 @@
 			int level = 0;
 			foreach (var evt in events)
 			{
-				switch (GetEventType(evt))
+				switch (evt.Type)
 				{
 					case EventType.YAML_DOCUMENT_START_EVENT:
 					case EventType.YAML_SEQUENCE_START_EVENT:
@@ -963,7 +908,7 @@
 			isMappingContext = isMapping;
 			isSimpleKeyContext = isSimpleKey;

-			var eventType = GetEventType(evt);
+			var eventType = evt.Type;
 			switch (eventType)
 			{
 				case EventType.YAML_ALIAS_EVENT:
@@ -1736,7 +1681,7 @@
 			}

 			int length;
-			switch (GetEventType(events.Peek()))
+			switch (events.Peek().Type)
 			{
 				case EventType.YAML_ALIAS_EVENT:
 					length = SafeStringLength(anchorData.anchor);


Add constraints to improve Options.GetString and Options.GetStrings usage

--- Sharpmake/Options.cs
+++ Sharpmake/Options.cs
@@ -274,7 +274,7 @@
             }
         }

-        public static Strings GetStrings<T>(Configuration conf)
+        public static Strings GetStrings<T>(Configuration conf) where T : Strings
         {
             List<object> options = conf.Options;
             Strings values = new Strings();
@@ -289,7 +289,7 @@
             return values;
         }

-        public static string GetString<T>(Configuration conf)
+        public static string GetString<T>(Configuration conf) where T : StringOption
         {
             List<object> options = conf.Options;


changing

changing

--- GOL/MainWindow.xaml.cs
+++ GOL/MainWindow.xaml.cs
@@ -366,8 +366,8 @@
             ReplayOn = !ReplayOn;
             if (ReplayOn)
             {
+                handler.setSavedGameId(SavedGameId);
                 timer.Start();
-
             }
             if (!ReplayOn)
             {
@@ -425,7 +425,6 @@
             {

                 SavedGameId = itemSelected;
-                handler.setSavedGameId(SavedGameId);
                 handler.ResetGenNumber();
                 handler.LoadGenFromDatabase();
                 buttonReplay.IsHitTestVisible = true;


api: added a PreferredEncoding property to Repository which shall be used for encoding conversion on api level. this is not yet implemented though.

--- GitSharp/Repository.cs
+++ GitSharp/Repository.cs
@@ -58,6 +58,7 @@

         internal Repository(CoreRepository repo)
         {
+            PreferredEncoding = Encoding.UTF8;
             _internal_repo = repo;
         }

@@ -344,6 +345,15 @@
             return "Repository[" + Directory + "]";
         }

+        /// <summary>
+        /// If data in a repository (i.e. filenames, commit messages, etc. ) is to be decoded with a special encoding
+        /// set this property. Default setting is UTF8
+        /// </summary>
+        public Encoding PreferredEncoding
+        {
+            get;
+            set;
+        }

         public void Close()
         {


Include signing_redirect_url in file-based sig requests

--- HelloSign/HelloSign.cs
+++ HelloSign/HelloSign.cs
@@ -430,6 +430,7 @@
             if (signatureRequest.Subject != null) request.AddParameter("subject", signatureRequest.Subject);
             if (signatureRequest.Message != null) request.AddParameter("message", signatureRequest.Message);
             if (signatureRequest.TestMode) request.AddParameter("test_mode", "1");
+            if (signatureRequest.SigningRedirectUrl != null) request.AddParameter("signing_redirect_url", signatureRequest.SigningRedirectUrl);
             if (signatureRequest.UseTextTags) request.AddParameter("use_text_tags", "1");
             if (signatureRequest.HideTextTags) request.AddParameter("hide_text_tags", "1");


Added Server Forwarding for Emotes

Added Server Forwarding for Emotes

Lemme know if I goofed it up

--- Iris/Classes/Server.cs
+++ Iris/Classes/Server.cs
@@ -121,6 +121,9 @@
                 case "KILLER":
                     HandleKILLER(msg);
                     break;
+                case "EMOTE":
+                    HandleKILLER(msg);
+                    break;
                 default:
                     Console.WriteLine(string.Format("Bad message type {0} from player {1}",
                         type, msg.SenderConnection.RemoteUniqueIdentifier));
@@ -137,6 +140,18 @@
             outMsg.Write("KILLER");
             outMsg.Write(owner);
             outMsg.Write(victim);
+            server.SendToAll(outMsg, null, NetDeliveryMethod.ReliableOrdered, 0);
+        }
+
+        private void HandleEMOTE(NetIncomingMessage msg)
+        {
+            long owner = msg.SenderConnection.RemoteUniqueIdentifier;
+            string emoteType = msg.ReadString();
+
+            NetOutgoingMessage outMsg = server.CreateMessage();
+            outMsg.Write("EMOTE");
+            outMsg.Write(owner);
+            outMsg.Write(emoteType);
             server.SendToAll(outMsg, null, NetDeliveryMethod.ReliableOrdered, 0);
         }


Fix alignment bug in checker prompt

Fix alignment bug in checker prompt

--- HaveIBeenPwned/CheckerPrompt.Designer.cs
+++ HaveIBeenPwned/CheckerPrompt.Designer.cs
@@ -68,7 +68,7 @@
             this.checkOldEntries.AutoSize = true;
             this.checkOldEntries.Checked = true;
             this.checkOldEntries.CheckState = System.Windows.Forms.CheckState.Checked;
-            this.checkOldEntries.Location = new System.Drawing.Point(12, 59);
+            this.checkOldEntries.Location = new System.Drawing.Point(13, 59);
             this.checkOldEntries.Name = "checkOldEntries";
             this.checkOldEntries.Size = new System.Drawing.Size(331, 17);
             this.checkOldEntries.TabIndex = 2;


Use csexec to run LanguagePackBuilder.cs

--- LanguagePackBuilder.cs
+++ LanguagePackBuilder.cs
@@ -1,14 +1,28 @@
-#!/usr/bin/csharp
-
-// already defined:
-// using System;
-// using System.Collections.Generic;
-
+#!/usr/bin/csexec
+
+using System;
 using System.IO;
 using System.Text;
 using System.Diagnostics;
-
-class LanguagePackBuilder
+using System.Collections.Generic;
+
+public static class Program
+{
+	public static void Main (string [] args)
+	{
+		try
+		{
+			var script = new LanguagePackBuilder ();
+			script.Run ();
+		}
+		catch (Exception ex)
+		{
+			Console.WriteLine (ex.Message);
+		}
+	}
+}
+
+internal class LanguagePackBuilder
 {
 	#region Parameters

@@ -17,23 +31,23 @@
 	public string CultureNameNative = Environment.GetEnvironmentVariable ("LPB_CULTURE_NAME_NATIVE");
 	public string PackageType = Environment.GetEnvironmentVariable ("LPB_PACKAGE_TYPE");
 	public string PackageName = Environment.GetEnvironmentVariable ("LPB_PACKAGE_NAME");
-	public string SourceVersion = Environment.GetEnvironmentVariable ("LPB_SOURCE_VERSION");
+	public string SourceVersion = Environment.GetEnvironmentVariable ("LPB_SOURCE_VERSION");
 	public string PlatformType = Environment.GetEnvironmentVariable ("LBP_PLATFORM_TYPE");
-
+
 	public string ManifestFileNameTemplate = "R7_${PlatformType}_${PackageType}_${PackageName}_${CultureCode}.dnn";
 	public string PackFileNameTemplate = "ResourcePack.R7.${PlatformType}.${PackageType}.${PackageName}.${SourceVersion}-${PackageVersion}.${CultureCode}.zip";

 	#endregion

-	public void Main ()
-	{
-		try
+	public void Run ()
+	{
+		try
 		{
 			CreatePackage (GenerateManifest ());
 		}
 		catch (Exception ex)
 		{
-			Console.WriteLine (ex.Message);
+			throw ex;
 		}
 	}

@@ -46,16 +60,16 @@
 			var startTag = "<languageFile>";
 			var endTag = "</languageFile>";

-			var begin = manifestTemplate.IndexOf (startTag);
+			var begin = manifestTemplate.IndexOf (startTag);
 			var end = manifestTemplate.IndexOf (endTag) + endTag.Length;

 			// get template for languageFile entries
 			var langFileTemplate = manifestTemplate.Substring (begin, end - begin);
-
+
 			// get translation files
 			Directory.SetCurrentDirectory (Path.Combine (PackageName, CultureCode));
 			var files = Directory.GetFiles (".", "*.ru-RU.resx", SearchOption.AllDirectories);
-
+
 			// for better formatting
 			var line = 0;

@@ -82,9 +96,9 @@
 			manifest = ReplaceTags (manifest);

 			var manifestFileName = ReplaceTags (ManifestFileNameTemplate);
-
+
 			File.WriteAllText (manifestFileName, manifest);
-
+
 			Directory.SetCurrentDirectory (Path.Combine ("..", ".."));

 			return manifestFileName;
@@ -98,18 +112,18 @@
 	private void CreatePackage (string manifestFileName)
 	{
 		try
-		{
+		{
 			var packFileName = Path.Combine ("..", ReplaceTags (PackFileNameTemplate));

 			// copy translations to tmp folder
-
+
 			Console.WriteLine (Directory.GetCurrentDirectory());
-
+
 			Directory.SetCurrentDirectory (Path.Combine (PackageName, CultureCode));
-
+
 			// delete old package
 			if (File.Exists (packFileName))
-				File.Delete (packFileName);
+				File.Delete (packFileName);

 			// create package
 			var zip = new Process ();
@@ -117,10 +131,10 @@
 			zip.StartInfo.Arguments = string.Format (@"-q -r -9 -i \*.resx \*.dnn -UN=UTF8 ""{0}"" .", packFileName);
 			zip.Start ();
 			zip.WaitForExit ();
-
+
 			// delete manifest file
 			File.Delete (manifestFileName);
-
+
 			Directory.SetCurrentDirectory (Path.Combine ("..", ".."));
 		}
 		catch (Exception ex)
@@ -141,9 +155,9 @@
 		}

 		// Extension language pack name
-		result = result.Replace ("${ExtensionName}",
+		result = result.Replace ("${ExtensionName}",
 			(PackageType == "Extension")? PackageName + " " : string.Empty);
-
+
 		result = result.Replace ("${CultureCode}", CultureCode);
 		result = result.Replace ("${CultureNameNative}", CultureNameNative);
 		result = result.Replace ("${PackageType}", PackageType);
@@ -151,12 +165,12 @@
 		result = result.Replace ("${PlatformType}", PlatformType);
 		result = result.Replace ("${SourceVersion}", SourceVersion);
 		result = result.Replace ("${PackageVersion}", PackageVersion);
-
+
 		return result;
 	}

 	private List<string> RunToLines (string command, string arguments)
-	{
+	{
 		var result = new List<string> ();

 		var process = new Process ();
@@ -165,7 +179,7 @@
 		process.StartInfo.UseShellExecute = false;
 		process.StartInfo.RedirectStandardOutput = true;

-		try
+		try
 		{
 			process.Start ();
 			process.WaitForExit ();
@@ -192,10 +206,3 @@
 		return !string.IsNullOrWhiteSpace (variableValue)? variableValue : defaultValue;
 	}
 }
-
-new LanguagePackBuilder().Main();
-
-
-
-
-


MAINT: add a listener for debugging data-binding

--- MPLite/App.xaml.cs
+++ MPLite/App.xaml.cs
@@ -5,6 +5,7 @@
 using System.Linq;
 using System.Threading.Tasks;
 using System.Windows;
+using System.Diagnostics;

 namespace MPLite
 {
@@ -25,5 +26,33 @@
             MessageBox.Show(e.Exception.StackTrace);
             e.Handled = true;
         }
+
+        // ref: https://spin.atomicobject.com/2013/12/11/wpf-data-binding-debug
+        protected override void OnStartup(StartupEventArgs e)
+        {
+            SetListener();
+            base.OnStartup(e);
+        }
+
+        [Conditional("DEBUG")]
+        private void SetListener()
+        {
+            PresentationTraceSources.Refresh();
+            PresentationTraceSources.DataBindingSource.Listeners.Add(new ConsoleTraceListener());
+            PresentationTraceSources.DataBindingSource.Listeners.Add(new DebugTraceListener());
+            PresentationTraceSources.DataBindingSource.Switch.Level = SourceLevels.Warning | SourceLevels.Error;
+        }
+    }
+
+    public class DebugTraceListener : TraceListener
+    {
+        public override void Write(string message)
+        {
+        }
+
+        public override void WriteLine(string message)
+        {
+            Debugger.Break();
+        }
     }
 }


Cut huge locations

Cut huge locations

--- JoinProto/Controllers/UsersController.cs
+++ JoinProto/Controllers/UsersController.cs
@@ -89,6 +89,8 @@

             db.Users.Add(user);
             await db.SaveChangesAsync();
+
+            user.Locations = user.Locations?.Take(10).ToList();
             return CreatedAtRoute("DefaultApi", new { id = user.Id }, user);
         }


Fix vk saving in profile

Fix vk saving in profile

--- JoinRpg.Services.Impl/UserServiceImpl.cs
+++ JoinRpg.Services.Impl/UserServiceImpl.cs
@@ -35,7 +35,7 @@
       user.Extra.Nicknames = nicknames;
       user.Extra.GroupNames = groupNames;
       user.Extra.Skype = skype;
-      var tokensToRemove = new[] {"http://", "vk.com/", "vkontakte.ru/", ".livejournal.com", ".lj.ru", "/", "https://"};
+      var tokensToRemove = new[] {"http://", "https://", "vk.com/", "vkontakte.ru/", ".livejournal.com", ".lj.ru", "/", };
       user.Extra.Livejournal = livejournal.RemoveFromString(tokensToRemove);
       user.Extra.Vk = vk.RemoveFromString(tokensToRemove);


Fixed typo the correct way

Fixed typo the correct way

--- KodiInterop/KodiInterop/PythonInterop.cs
+++ KodiInterop/KodiInterop/PythonInterop.cs
@@ -49,7 +49,7 @@

 			if (escapeMethod.HasFlag(EscapeFlags.Quotes)) {
 				text = Regex.Replace(text, "\r?\n", "\\n");
-				text = "'" + text.Replace("\"", "\\\"") + '"';
+				text = '"' + text.Replace("\"", "\\\"") + '"';
 			}
 			if (escapeMethod.HasFlag(EscapeFlags.EscapeBuiltin)) {
 				text = Regex.Replace(text, ",", "\\,");


Add100

--- LabWs1/SimpleWebApp/FirstService.asmx.cs
+++ LabWs1/SimpleWebApp/FirstService.asmx.cs
@@ -32,6 +32,11 @@
         public string NumToEng(int number)
         {
             return NumberToWords(number);
+        }
+        [WebMethod]
+        public string Add100(int number)
+        {
+            return string.Format("After add 100: {0}", number + 100);
         }

         public static string NumberToWords(int number)


Libraries/DAL: working on information

Libraries/DAL: working on information

--- Libraries/DAL/DatabaseAbstrationLayer.cs
+++ Libraries/DAL/DatabaseAbstrationLayer.cs
@@ -29,10 +29,17 @@
 		/// <param name="ic">The interest to add</param>
 		public async Task AddInterest (Interest ic)
 		{
-				await client.Cypher
-					.Create ("(interest:Interest {val: info})")
-					.WithParam ("info", ic)
-					.ExecuteWithoutResultsAsync ();
+			var newInterest = new {value = ic};
+
+			await client.Cypher
+				.Merge ("(interest:Interest {val: {Val}})")
+				.OnCreate ()
+				.Set ("interest = {newInterest}")
+				.WithParams ( new {
+					Val = newInterest.value,
+					newInterest
+				})
+				.ExecuteWithoutResultsAsync ();
 		}

 		/// <summary>
@@ -42,9 +49,16 @@
 		/// <param name="lc">The language to add</param>
 		public async Task AddLanguage (Language lc)
 		{
-			await client.Cypher
-				.Create ("(language:Language {val: info})")
-				.WithParam ("info", lc)
+			var newLanguage = new {value = lc};
+
+			await client.Cypher
+				.Merge ("(language:Language {val: {Val}})")
+				.OnCreate ()
+				.Set ("language = {Language}")
+				.WithParams ( new {
+					Val = newLanguage.value,
+					newLanguage
+				})
 				.ExecuteWithoutResultsAsync ();
 		}

@@ -55,9 +69,16 @@
 		/// <param name="fh">The foodhabit to add</param>
 		public async Task AddFoodHabit (FoodHabit fh)
 		{
-			await client.Cypher
-				.Create ("(foodhabit:FoodHabit {val: info})")
-				.WithParam ("info", fh)
+			var newFoodHabit = new {value = fh};
+
+			await client.Cypher
+				.Merge ("(foodhabit:FoodHabit {val: {Val}})")
+				.OnCreate ()
+				.Set ("foodhabit = {newFoodHabit}")
+				.WithParams ( new {
+					Val = newFoodHabit.value,
+					newFoodHabit
+				})
 				.ExecuteWithoutResultsAsync ();
 		}


updated reference with new directorypath functions

--- MSOE.MediaComplete.Lib/Sorting/Sorter.cs
+++ MSOE.MediaComplete.Lib/Sorting/Sorter.cs
@@ -80,7 +80,7 @@
                     }

                     // If the target path doesn't fulfill the sort settings, bump the counter.
-                    if (targetPath.FullPath.Remove(0, SettingWrapper.MusicDir.FullPath.Length).Split(Path.DirectorySeparatorChar).Count() != SettingWrapper.SortOrder.Count + 1)
+                    if (targetPath.FullPath.Remove(0, SettingWrapper.MusicDir.Length).Split(Path.DirectorySeparatorChar).Count() != SettingWrapper.SortOrder.Count + 1)
                     {
                         UnsortableCount++;
                     }


added a fix, looking to improve it if possible. Generally displeased with the implementation

--- MSOE.MediaComplete/MainWindowMetadata.cs
+++ MSOE.MediaComplete/MainWindowMetadata.cs
@@ -1,6 +1,8 @@
 using System;
 using System.Collections.Generic;
+using System.Linq;
 using System.Windows;
+using System.Windows.Forms.DataVisualization.Charting;
 using MSOE.MediaComplete.CustomControls;
 using MSOE.MediaComplete.Lib;
 using TagLib;
@@ -61,8 +63,16 @@
                     {MetaAttribute.Year, null},
                     {MetaAttribute.Rating, null}
                 };
+                var escape = 0;
                 foreach ( SongTreeViewItem item in SongTree.SelectedItems)
                 {
+                    var allVals = attributes.Values.ToArray();
+                    foreach (var val in allVals)
+                    {
+                        if (val == null) break;
+                        if (val.Equals("-1") || val.Trim().Equals("")) escape++;
+                    }
+                    if (escape == 8) break;
                     try
                     {
                         var song = File.Create(item.GetPath());
@@ -235,10 +245,10 @@
                     changedBox.Redo();
                     changedBox.LockCurrentUndoUnit();
                 }
+                if(_changedBoxes.Count != 0) PopulateMetadataForm();
                 _changedBoxes.Clear();
                 ToggleReadOnlyFields(true);
                 EditCancelButton.Content = "Edit";
-                PopulateMetadataForm();
             }
         }


Update /guitars page description

Update /guitars page description

--- MichaelsMusic/Views/Guitars/index.cshtml
+++ MichaelsMusic/Views/Guitars/index.cshtml
@@ -2,7 +2,7 @@
 @{
     Layout = "~/Views/Shared/_Layout.cshtml";
     ViewBag.Title = "Guitars";
-    ViewBag.Description = "This is the guitar collections page. These are all guitars that I either: own, used to own, or wish I owned (which is most of them). If you want to look at guitars, but you're not sure which ones, this is the right place to start.";
+    ViewBag.Description = "This is the guitars collection page. If you want to look at guitars, but you're not sure which ones, this is the right place to start.";
     ViewBag.Keywords = "guitars, mcnaught guitars, mcnaught vintage double cut, prs, prs guitars, paul reed smith, paul reed smith guitars, paul reed smith custom 24, prs custom 24, paul reed smith mccarty, prs mccarty, peavey hp custom, gibson midtown custom, king bee oak cliff, 1980 gibson les paul custom, collings city limits deluxe, collings cl deluxe";
 }


fix: remove assertions from functional tests (#206)

--- Minio.Functional.Tests/FunctionalTest.cs
+++ Minio.Functional.Tests/FunctionalTest.cs
@@ -405,7 +405,6 @@
             catch (MinioException ex)
             {
                 new MintLogger("MakeBucket_Test4",makeBucketSignature,"Tests whether MakeBucket with region and bucketname with . passes",TestStatus.FAIL,(DateTime.Now - startTime),"",ex.Message, ex.ToString(),args).Log();
-                //Assert.Fail();
             }
         }

@@ -725,92 +724,76 @@
         private async static Task PutObject_Task(MinioClient minio, string bucketName, string objectName, string fileName = null, string contentType = "application/octet-stream", long size = 0, Dictionary<string, string> metaData = null, MemoryStream mstream = null)
         {
             DateTime startTime = DateTime.Now;
-            try
-            {
-                System.IO.MemoryStream filestream = mstream;
-                if (filestream == null)
-                {
-                    byte[] bs = File.ReadAllBytes(fileName);
-                    filestream = new System.IO.MemoryStream(bs);
-
-                }
-                using (filestream)
-                {
-                    long file_write_size = filestream.Length;
-                    string tempFileName = "tempfile-" + GetRandomName(5);
-                    if (size == 0)
-                        size = filestream.Length;
-
-                    await minio.PutObjectAsync(bucketName,
-                                               objectName,
-                                               filestream,
-                                               size,
-                                               contentType,
-                                               metaData: metaData);
-                    File.Delete(tempFileName);
-                }
-            }
-            catch (Exception ex)
-            {
-                Assert.Fail();
-                throw ex;
-            }
-            return;
+
+            System.IO.MemoryStream filestream = mstream;
+            if (filestream == null)
+            {
+                byte[] bs = File.ReadAllBytes(fileName);
+                filestream = new System.IO.MemoryStream(bs);
+
+            }
+            using (filestream)
+            {
+                long file_write_size = filestream.Length;
+                string tempFileName = "tempfile-" + GetRandomName(5);
+                if (size == 0)
+                    size = filestream.Length;
+
+                await minio.PutObjectAsync(bucketName,
+                                            objectName,
+                                            filestream,
+                                            size,
+                                            contentType,
+                                            metaData: metaData);
+                File.Delete(tempFileName);
+            }
         }
         private async static Task<ObjectStat> PutObject_Tester(MinioClient minio, string bucketName, string objectName, string fileName = null, string contentType = "application/octet-stream", long size = 0, Dictionary<string, string> metaData = null, MemoryStream mstream = null)
         {
             ObjectStat statObject = null;
             DateTime startTime = DateTime.Now;

-            try
-            {
-                System.IO.MemoryStream filestream = mstream;
-                if (filestream == null)
-                {
-                    byte[] bs = File.ReadAllBytes(fileName);
-                    filestream = new System.IO.MemoryStream(bs);
-
-                }
-                using (filestream)
-                {
-                    long file_write_size = filestream.Length;
-                    long file_read_size = 0;
-                    string tempFileName = "tempfile-" + GetRandomName(5);
-                    if (size == 0)
-                        size = filestream.Length;
-
-                    await minio.PutObjectAsync(bucketName,
-                                               objectName,
-                                               filestream,
-                                               size,
-                                               contentType,
-                                               metaData: metaData);
-                    await minio.GetObjectAsync(bucketName, objectName,
-                    (stream) =>
-                    {
-                       var fileStream = File.Create(tempFileName);
-                       stream.CopyTo(fileStream);
-                       fileStream.Dispose();
-                       FileInfo writtenInfo = new FileInfo(tempFileName);
-                       file_read_size = writtenInfo.Length;
-
-                       Assert.AreEqual(file_read_size, file_write_size);
-                       File.Delete(tempFileName);
-                    });
-                    statObject = await minio.StatObjectAsync(bucketName, objectName);
-                    Assert.IsNotNull(statObject);
-                    Assert.AreEqual(statObject.ObjectName, objectName);
-                    Assert.AreEqual(statObject.Size, file_read_size);
-                    if (contentType != null)
-                        Assert.AreEqual(statObject.ContentType, contentType);
-
-                    await minio.RemoveObjectAsync(bucketName, objectName);
-                }
-            }
-            catch (Exception ex)
-            {
-                Assert.Fail();
-                throw ex;
+            System.IO.MemoryStream filestream = mstream;
+            if (filestream == null)
+            {
+                byte[] bs = File.ReadAllBytes(fileName);
+                filestream = new System.IO.MemoryStream(bs);
+
+            }
+            using (filestream)
+            {
+                long file_write_size = filestream.Length;
+                long file_read_size = 0;
+                string tempFileName = "tempfile-" + GetRandomName(5);
+                if (size == 0)
+                    size = filestream.Length;
+
+                await minio.PutObjectAsync(bucketName,
+                                            objectName,
+                                            filestream,
+                                            size,
+                                            contentType,
+                                            metaData: metaData);
+                await minio.GetObjectAsync(bucketName, objectName,
+                (stream) =>
+                {
+                    var fileStream = File.Create(tempFileName);
+                    stream.CopyTo(fileStream);
+                    fileStream.Dispose();
+                    FileInfo writtenInfo = new FileInfo(tempFileName);
+                    file_read_size = writtenInfo.Length;
+
+                    Assert.AreEqual(file_read_size, file_write_size);
+                    File.Delete(tempFileName);
+                });
+                statObject = await minio.StatObjectAsync(bucketName, objectName);
+                Assert.IsNotNull(statObject);
+                Assert.AreEqual(statObject.ObjectName, objectName);
+                Assert.AreEqual(statObject.Size, file_read_size);
+                if (contentType != null)
+                    Assert.AreEqual(statObject.ContentType, contentType);
+
+                await minio.RemoveObjectAsync(bucketName, objectName);
             }
             return statObject;
         }
@@ -972,16 +955,7 @@

                 CopyConditions conditions = new CopyConditions();
                 conditions.SetMatchETag(stats.ETag);
-                try
-                {
-                    await minio.CopyObjectAsync(bucketName, objectName, destBucketName, destObjectName, conditions);
-
-                }
-                catch (MinioException)
-                {
-                    Assert.Fail();
-                }
-
+                await minio.CopyObjectAsync(bucketName, objectName, destBucketName, destObjectName, conditions);
                 string outFileName = "outFileName";
                 ObjectStat dstats = await minio.StatObjectAsync(destBucketName, destObjectName);
                 Assert.IsNotNull(dstats);
@@ -1142,17 +1116,7 @@
                 CopyConditions conditions = new CopyConditions();
                 conditions.SetModified(new DateTime(2017, 8, 18));
                 // Should copy object since modification date header < object modification date.
-                try
-                {
-                    await minio.CopyObjectAsync(bucketName, objectName, destBucketName, destObjectName, conditions);
-
-                }
-                catch (MinioException ex)
-                {
-                    Assert.Fail();
-                    throw ex;
-                }
-
+                await minio.CopyObjectAsync(bucketName, objectName, destBucketName, destObjectName, conditions);
                 string outFileName = "outFileName";
                 ObjectStat dstats = await minio.StatObjectAsync(destBucketName, destObjectName);
                 Assert.IsNotNull(dstats);
@@ -1247,39 +1211,32 @@
             try
             {
                 await Setup_Test(minio, bucketName);
-                try
-                {
-                    using (System.IO.MemoryStream filestream = rsg.GenerateStreamFromSeed(1 * MB))
+
+                using (System.IO.MemoryStream filestream = rsg.GenerateStreamFromSeed(1 * MB))
+                {
+                    long file_write_size = filestream.Length;
+                    string tempFileName = "tempFileName";
+                    long file_read_size = 0;
+                    await minio.PutObjectAsync(bucketName,
+                                            objectName,
+                                            filestream,
+                                            filestream.Length,
+                                            contentType);
+
+                    await minio.GetObjectAsync(bucketName, objectName,
+                    (stream) =>
                     {
-                        long file_write_size = filestream.Length;
-                        string tempFileName = "tempFileName";
-                        long file_read_size = 0;
-                        await minio.PutObjectAsync(bucketName,
-                                                objectName,
-                                                filestream,
-                                                filestream.Length,
-                                                contentType);
-
-                        await minio.GetObjectAsync(bucketName, objectName,
-                        (stream) =>
-                        {
-                            var fileStream = File.Create(tempFileName);
-                            stream.CopyTo(fileStream);
-                            fileStream.Dispose();
-                            FileInfo writtenInfo = new FileInfo(tempFileName);
-                            file_read_size = writtenInfo.Length;
-
-                            Assert.AreEqual(file_read_size, file_write_size);
-                            File.Delete(tempFileName);
-                        });
-
-                        await minio.RemoveObjectAsync(bucketName, objectName);
-                    }
-                }
-                catch (Exception ex)
-                {
-                    Assert.Fail();
-                    throw ex;
+                        var fileStream = File.Create(tempFileName);
+                        stream.CopyTo(fileStream);
+                        fileStream.Dispose();
+                        FileInfo writtenInfo = new FileInfo(tempFileName);
+                        file_read_size = writtenInfo.Length;
+
+                        Assert.AreEqual(file_read_size, file_write_size);
+                        File.Delete(tempFileName);
+                    });
+
+                    await minio.RemoveObjectAsync(bucketName, objectName);
                 }
                 await TearDown(minio, bucketName);

@@ -1342,47 +1299,39 @@
             try
             {
                 await Setup_Test(minio, bucketName);
-                try
-                {
-                    using (System.IO.MemoryStream filestream = rsg.GenerateStreamFromSeed(1 * MB))
+                using (System.IO.MemoryStream filestream = rsg.GenerateStreamFromSeed(1 * MB))
+                {
+                    long file_write_size = 10L;
+                    string tempFileName = "tempFileName";
+                    long file_read_size = 0;
+                    await minio.PutObjectAsync(bucketName,
+                                            objectName,
+                                            filestream,
+                                            filestream.Length,
+                                            contentType);
+
+                    await minio.GetObjectAsync(bucketName, objectName, 1024L, file_write_size,
+                    (stream) =>
                     {
-                        long file_write_size = 10L;
-                        string tempFileName = "tempFileName";
-                        long file_read_size = 0;
-                        await minio.PutObjectAsync(bucketName,
-                                                objectName,
-                                                filestream,
-                                                filestream.Length,
-                                                contentType);
-
-                        await minio.GetObjectAsync(bucketName, objectName, 1024L, file_write_size,
-                        (stream) =>
-                        {
-                            var fileStream = File.Create(tempFileName);
-                            stream.CopyTo(fileStream);
-                            fileStream.Dispose();
-                            FileInfo writtenInfo = new FileInfo(tempFileName);
-                            file_read_size = writtenInfo.Length;
-
-                            Assert.AreEqual(file_read_size, file_write_size);
-                            File.Delete(tempFileName);
-                        });
-
-                        await minio.RemoveObjectAsync(bucketName, objectName);
-                    }
-            }
-            catch (Exception ex)
-            {
-                    Assert.Fail();
-                    throw ex;
-            }
-            await TearDown(minio, bucketName);
-            new MintLogger("GetObject_Test3",getObjectSignature2,"Tests whether GetObject returns all the data",TestStatus.PASS,(DateTime.Now - startTime), args:args).Log();
-        }
-        catch (MinioException ex)
-        {
-            new MintLogger("GetObject_Test3",getObjectSignature2,"Tests whether GetObject returns all the data",TestStatus.FAIL,(DateTime.Now - startTime),"",ex.Message, ex.ToString(),args).Log();
-        }
+                        var fileStream = File.Create(tempFileName);
+                        stream.CopyTo(fileStream);
+                        fileStream.Dispose();
+                        FileInfo writtenInfo = new FileInfo(tempFileName);
+                        file_read_size = writtenInfo.Length;
+
+                        Assert.AreEqual(file_read_size, file_write_size);
+                        File.Delete(tempFileName);
+                    });
+
+                    await minio.RemoveObjectAsync(bucketName, objectName);
+                }
+                await TearDown(minio, bucketName);
+                new MintLogger("GetObject_Test3",getObjectSignature2,"Tests whether GetObject returns all the data",TestStatus.PASS,(DateTime.Now - startTime), args:args).Log();
+            }
+            catch (MinioException ex)
+            {
+                new MintLogger("GetObject_Test3",getObjectSignature2,"Tests whether GetObject returns all the data",TestStatus.FAIL,(DateTime.Now - startTime),"",ex.Message, ex.ToString(),args).Log();
+            }

         }
         private async static Task FGetObject_Test1(MinioClient minio)
@@ -2065,8 +2014,8 @@
                 }
                 catch (Exception ex)
                 {
-                    Assert.Fail();
-                    throw ex;
+                    new MintLogger("ListIncompleteUpload_Test1",listIncompleteUploadsSignature,"Tests whether ListIncompleteUpload passes",TestStatus.FAIL,(DateTime.Now - startTime),"",ex.Message, ex.ToString()).Log();
+                    return;
                 }
                 await TearDown(minio, bucketName);
                 new MintLogger("ListIncompleteUpload_Test1",listIncompleteUploadsSignature, "Tests whether ListIncompleteUpload passes",TestStatus.PASS,(DateTime.Now - startTime)).Log();
@@ -2117,10 +2066,6 @@

                     await minio.RemoveIncompleteUploadAsync(bucketName, objectName);
                 }
-                catch (Exception ex)
-                {
-                    Assert.Fail();
-                }
                 await TearDown(minio, bucketName);
                 new MintLogger("ListIncompleteUpload_Test2",listIncompleteUploadsSignature,"Tests whether ListIncompleteUpload passes when qualified by prefix",TestStatus.PASS,(DateTime.Now - startTime), args:args).Log();
             }
@@ -2171,10 +2116,6 @@

                     await minio.RemoveIncompleteUploadAsync(bucketName, objectName);
                 }
-                catch (Exception ex)
-                {
-                    Assert.Fail();
-                }
                 await TearDown(minio, bucketName);
                 new MintLogger("ListIncompleteUpload_Test3",listIncompleteUploadsSignature,"Tests whether ListIncompleteUpload passes when qualified by prefix and recursive",TestStatus.PASS,(DateTime.Now - startTime), args:args).Log();
             }
@@ -2222,11 +2163,6 @@
                     IDisposable subscription = observable.Subscribe(
                         item => Assert.Fail(),
                         ex => Assert.Fail());
-                }
-                catch (Exception ex)
-                {
-                    Assert.Fail();
-                    throw ex;
                 }
                 await TearDown(minio, bucketName);
                 new MintLogger("RemoveIncompleteUpload_Test",removeIncompleteUploadSignature,"Tests whether RemoveIncompleteUpload passes.",TestStatus.PASS,(DateTime.Now - startTime), args:args).Log();


fixed issue with non-default archives having fomod options marked as default

--- ModAnalyzer/Domain/ModAnalyzerService.cs
+++ ModAnalyzer/Domain/ModAnalyzerService.cs
@@ -109,7 +109,10 @@
         private void AnalyzeArchive(ModOption modOption) {
             if (modOption.IsFomodArchive) {
                 List<ModOption> fomodOptions = AnalyzeFomodArchive(modOption);
-                fomodOptions.ForEach(mo => { mo.MD5Hash = modOption.MD5Hash; });
+                fomodOptions.ForEach(mo => {
+                    mo.MD5Hash = modOption.MD5Hash;
+                    mo.Default = mo.Default && modOption.Default;
+                });
                 _modAnalysis.ModOptions.Add(modOption);
                 _modAnalysis.ModOptions.AddRange(fomodOptions);
             } else if (modOption.IsBainArchive) {