A classic Star Trek episode is presented the way its original creator intended in IDW Publishing’s The City on the Edge of Forever: The Original Teleplay. Based on the late science fiction novelist Harlan Ellison’s original screenplay of the same name, this five-issue miniseries was adapted by Scott and David Tipton, who have worked on other IDW Star Trek books, with painted art by J.K. Woodward of Fallen Angel fame.

The original filmed version of “City on the Edge of Forever” is classic Star Trek; it regularly appears in fan and critic lists of best Star Trek episodes from across the entire franchise. What fans may not know however is that what was ultimately aired and what original writer Harlan Ellison intended were two different things. Star Trek creator Gene Roddenberry was not happy with some elements of Ellison’s script (more on those in a minute) and rewrote whole parts, but not enough to get co-writer credit; the aired version is still fully attributed to Ellison. Ellison’s original screenplay was later published in book format and circulated among fans; IDW’s adaptation is the first mass release of this version, and the differences are on full display.

Related: Star Trek: The Borg Tried to Stop First Contact...Because of Doctor Who

The basic plot remains the same: a drugged-out crew member jumps through a time portal and alters Earth’s history beyond recognition. Kirk and Spock must then travel to the past to restore events. In both stories, a woman named Edith Keeler, and her death, is integral to the plot; both versions feature Kirk falling in love with Keeler. The similarities end there. In Ellison’s version it is not Doctor McCoy who travels back to the past and alters history, it is a random crew member caught dealing in narcotics, which Roddenberry apparently had issues with. The Guardian of Forever, the time portal, is also different. And at the end, the strung-out officer is killed, ripped apart by the currents of time.

Despite this different ending, the stories arrive at the same moral conclusion: Kirk and company return to their present, and Kirk lives out his life haunted by the loss of the one woman he actually loved. Compounding the loss is she had to die in order for history to be restored - a fact which the logical Spock (who deals with old-fashioned Earth racism as he and Kirk try to subsist in the past) reminded him of throughout their adventure.

IDW’s adaption of Ellison’s original vision for the story is a fascinating opportunity for Star Trek fans to revisit this episode from a new angle, with Ellison focusing more on the darkness and urgency found in the clash between human weakness and higher responsibilities. Some elements are out of character for Trek, such as a narcotics-addled Starfleet officer, but at its core it is pure Star Trek: a heavy ethical dilemma coupled with compelling characterization.

Next: Star Trek Theory: Discovery & Prodigy Are in the Same Time Period