input: Write a function to modify the given Python code to handle errors that may occur during the process of reading data from a JSON file. The function should print appropriate error messages for file not found and JSON decoding errors. The function should be called `read_data_from_json` and should take a filename as its parameter.
  assert read_data_from_json("nonexistent_file.json") == None
  assert read_data_from_json("invalid_json.json") == None
  assert read_data_from_json("valid_json_file.json") != None
output: def read_data_from_json(filename):
      try:
          with open(filename, 'r') as file:
              data = json.load(file)
              return data
      except FileNotFoundError:
          print(f"Error: File '{filename}' not found.")
          return None
      except json.JSONDecodeError:
          print(f"Error: Invalid JSON in file '{filename}'.")
          return None