diff --git a/tools/others/socialmedia.py b/tools/others/socialmedia.py index 27d6fce..3a1d0a2 100644 --- a/tools/others/socialmedia.py +++ b/tools/others/socialmedia.py @@ -1,4 +1,5 @@ # coding=utf-8 +import contextlib import os import subprocess @@ -48,7 +49,9 @@ class Faceshell(HackingTool): def run(self): name = input("Enter Username >> ") wordlist = input("Enter Wordlist >> ") - os.chdir("Brute_Force") + # Ignore a FileNotFoundError if we are already in the Brute_Force directory + with contextlib.suppress(FileNotFoundError): + os.chdir("Brute_Force") subprocess.run( ["python3", "Brute_Force.py", "-f", f"{name}", "-l", f"{wordlist}"])