Fixed insert method and updated files