def add_to_budget(self, client_pub: str, amount_sat: int) -> None:
        """
        If client_pub has a budget, check if the amount is within the budget and add it to the budget.
        Return True if the payment is allowed (within the budget)
        """
        if 'budget_spends' not in self.connections[client_pub]:
            self.connections[client_pub]['budget_spends'] = []
        # tuples don't work because jsondb converts them to lists on reload
        self.connections[client_pub]['budget_spends'].append([amount_sat, int(time.time())])

        If client_pub has a budget, check if the amount is within the budget and add it to the budget.
        Return True if the payment is allowed (within the budget)
        
electrum/plugins/nwc/nwcserver.py