File tree Expand file tree Collapse file tree 2 files changed +27
-9
lines changed
Expand file tree Collapse file tree 2 files changed +27
-9
lines changed Original file line number Diff line number Diff line change 2929// You can specify all the values or you can default the Build and Revision Numbers
3030// by using the '*' as shown below:
3131// [assembly: AssemblyVersion("1.0.*")]
32- [ assembly: AssemblyVersion ( "2.1.1 .0" ) ]
33- [ assembly: AssemblyFileVersion ( "2.1.1 .0" ) ]
32+ [ assembly: AssemblyVersion ( "2.1.2 .0" ) ]
33+ [ assembly: AssemblyFileVersion ( "2.1.2 .0" ) ]
3434
Original file line number Diff line number Diff line change 1- using SmartFormat ;
1+ using NLog ;
2+ using SmartFormat ;
23
34namespace XESmartTarget . Core . Utils
45{
56 public static class SmartFormatHelper
67 {
8+ private static Logger logger = LogManager . GetCurrentClassLogger ( ) ;
9+
10+ private static SmartFormatter fmt = Smart . CreateDefaultSmartFormat ( ) ;
711 public static string Format ( string format , Dictionary < string , string > args )
812 {
9- var fmt = Smart . CreateDefaultSmartFormat ( ) ;
10- fmt . Settings . Parser . ConvertCharacterStringLiterals = false ;
11- return fmt . Format ( format , args ) ;
13+ try
14+ {
15+ fmt . Settings . Parser . ConvertCharacterStringLiterals = false ;
16+ return fmt . Format ( format , args ) ;
17+ }
18+ catch ( Exception e )
19+ {
20+ logger . Debug ( e . Message ) ;
21+ return format ;
22+ }
1223 }
1324
1425 public static string Format ( string format , Dictionary < string , object > args )
1526 {
16- var fmt = Smart . CreateDefaultSmartFormat ( ) ;
17- fmt . Settings . Parser . ConvertCharacterStringLiterals = false ;
18- return fmt . Format ( format , args ) ;
27+ try
28+ {
29+ fmt . Settings . Parser . ConvertCharacterStringLiterals = false ;
30+ return fmt . Format ( format , args ) ;
31+ }
32+ catch ( Exception e )
33+ {
34+ logger . Debug ( e . Message ) ;
35+ return format ;
36+ }
1937 }
2038 }
2139}
You can’t perform that action at this time.
0 commit comments