input: Write a function to delete a specific node from a linked list. The function should take a node as an argument and remove it from the list if it exists. If the node is not found in the list, the function should do nothing. Return the modified linked list.
  
  class Node:
      def __init__(self, data):
          self.data = data
          self.next = None
  
  class LinkedList:
      def __init__(self):
          self.head = None
      
      def deleteNode(self, node):
          if self.head is None:
              return
          
          if self.head == node:
              self.head = self.head.next
              return
          
          current = self.head
          while current.next is not None:
              if current.next == node:
                  current.next = current.next.next
                  return
              current = current.next
  
  assert isinstance(test.deleteNode(node), type(LinkedList()))
  assert test.deleteNode(None) is None
  assert test.deleteNode(nonExistingNode) is None
output: def deleteNode(self, node):
      if self.head is None:
          return
      
      if self.head == node:
          self.head = self.head.next
          return
      
      current = self.head
      while current.next is not None:
          if current.next == node:
              current.next = current.next.next
              return
          current = current.next