Skip to content

Commit

Permalink
quick fix for --in-file exiting instead of returning
Browse files Browse the repository at this point in the history
  • Loading branch information
NSPC911 committed Sep 5, 2024
1 parent 148a9b1 commit f92b15f
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions search.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@
from custom_functions import *
from config import *
from colorama import Fore, init # type: ignore
import requests
import argparse
import requests, argparse

# Initialize colorama
init(strip=False, convert=False, autoreset=True)
Expand Down Expand Up @@ -41,7 +40,7 @@ def search_in_cwd(term, case_sensitive):

def search_in_file(file_path, term, case_sensitive):
if file_path.split(os.path.sep)[-1] != args.file_name and args.file_name != "*":
exit(0)
return

if term in str(file_path) and args.include_filename:
clear_line("-", "\n")
Expand Down

0 comments on commit f92b15f

Please sign in to comment.