Skip to content

Commit

Permalink
New Device creation int.replace issue #833
Browse files Browse the repository at this point in the history
  • Loading branch information
jokob-sk committed Oct 11, 2024
1 parent 30b8ecb commit f9e6871
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
7 changes: 5 additions & 2 deletions server/helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -852,8 +852,11 @@ def sanitize_string(input):
#-------------------------------------------------------------------------------
def sanitize_SQL_input(val):
if val is None:
return ''
return val.replace("'", "_")
return ''
if isinstance(val, str):
return val.replace("'", "_")
return val # Return non-string values as they are


#-------------------------------------------------------------------------------
# Function to normalize the string and remove diacritics
Expand Down
2 changes: 1 addition & 1 deletion server/networkscan.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ def process_scan (db):
mylog('none','[Process Scan] Stats end')

# Create Events
mylog('verbose','[Process Scan] Sessions Events (connect / discconnect)')
mylog('verbose','[Process Scan] Sessions Events (connect / disconnect)')
insert_events(db)

# Create New Devices
Expand Down

0 comments on commit f9e6871

Please sign in to comment.