PyFunceble/database.py
def remove(self):
        """
        Remove all occurence of :code:`PyFunceble.CONFIGURATION['to_test']`
        from the database.
        """

        if PyFunceble.CONFIGURATION["inactive_database"]:
            # The database subsystem is activated.

            if PyFunceble.INTERN["file_to_test"] in PyFunceble.INTERN["inactive_db"]:
                #  The file path is into the database.

                for data in PyFunceble.INTERN["inactive_db"][
                    PyFunceble.INTERN["file_to_test"]
                ]:
                    # We loop through the index of the file database.

                    if (
                        PyFunceble.INTERN["to_test"]
                        in PyFunceble.INTERN["inactive_db"][
                            PyFunceble.INTERN["file_to_test"]
                        ][data]
                    ):
                        # The currently tested element into the currently read index.

                        # We remove the currently tested element from the read index.
                        PyFunceble.INTERN["inactive_db"][
                            PyFunceble.INTERN["file_to_test"]
                        ][data].remove(PyFunceble.INTERN["to_test"])

            # And we save the data into the database.
            self._backup()
def remove(self):
        """
        Remove all occurence of :code:`PyFunceble.CONFIGURATION['to_test']`
        from the database.
        """

        if PyFunceble.CONFIGURATION["inactive_database"]:
            # The database subsystem is activated.

            if PyFunceble.INTERN["file_to_test"] in PyFunceble.INTERN["inactive_db"]:
                #  The file path is into the database.

                for data in PyFunceble.INTERN["inactive_db"][
                    PyFunceble.INTERN["file_to_test"]
                ]:
                    # We loop through the index of the file database.

                    if (
                        PyFunceble.INTERN["to_test"]
                        in PyFunceble.INTERN["inactive_db"][
                            PyFunceble.INTERN["file_to_test"]
                        ][data]
                    ):
                        # The currently tested element into the currently read index.

                        # We remove the currently tested element from the read index.
                        PyFunceble.INTERN["inactive_db"][
                            PyFunceble.INTERN["file_to_test"]
                        ][data].remove(PyFunceble.INTERN["to_test"])

            # And we save the data into the database.
            self._backup()
Remove all occurence of :code:`PyFunceble.CONFIGURATION['to_test']`
        from the database.