File tree Expand file tree Collapse file tree
Source/NETworkManager/ViewModels/Applications Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -262,11 +262,11 @@ private async void PortLookupAction()
262262 {
263263 if ( ( startPort > 0 ) && ( startPort < 65536 ) && ( endPort > 0 ) && ( endPort < 65536 ) && ( startPort < endPort ) )
264264 {
265- for ( int i = startPort ; i < endPort + 1 ; i ++ )
265+ for ( int i = startPort ; i < endPort + 1 ; i ++ )
266266 {
267267 ports . Add ( i ) ;
268268 }
269- }
269+ }
270270 else
271271 {
272272 portsByService . Add ( portOrService1 ) ;
@@ -299,16 +299,22 @@ private async void PortLookupAction()
299299 PortLookupResult . Add ( info ) ;
300300 }
301301
302- foreach ( PortLookupInfo info in await PortLookup . LookupByServiceAsync ( portsByService ) )
302+ foreach ( PortLookupInfo info in await PortLookup . LookupByServiceAsync ( portsByService ) )
303303 {
304304 PortLookupResult . Add ( info ) ;
305305 }
306-
307- PortsHistory = new List < string > ( HistoryListHelper . Modify ( PortsHistory , PortsOrService , SettingsManager . Current . Application_HistoryListEntries ) ) ;
308306
309- IsPortLookupRunning = false ;
307+ if ( PortLookupResult . Count == 0 )
308+ {
309+ NoPortsFound = true ;
310+ }
311+ else
312+ {
313+ PortsHistory = new List < string > ( HistoryListHelper . Modify ( PortsHistory , PortsOrService , SettingsManager . Current . Application_HistoryListEntries ) ) ;
314+ NoPortsFound = false ;
315+ }
310316
311- NoPortsFound = PortLookupResult . Count == 0 ;
317+ IsPortLookupRunning = false ;
312318 }
313319 #endregion
314320 }
You can’t perform that action at this time.
0 commit comments