Ghostd: Discovering Backend Development with a Dating App for Dead People

Scarlett Eller
4 min readMar 15, 2022

--

Phase Three in Flatiron School was my first exposure to backend programming. Having a background in artistic study and design, it was a part of programming I assumed would be quite unenjoyable for me. Moreover, I believed I would be pretty bad at it as well. For most of the phase I was often surprised how easily I took to it, especially when the problems were more material and dealt with realistic pieces of data.

When it came time to build our Third Phase projects, I was assigned Henry Miller as my project partner. We were pretty excited about this, as we’d had many conversations about building a unique and entertaining application. As beginner coders we knew the new Facebook was a little beyond our reach, but we wanted to work on a project that was simply fun both to use and to create. We first discussed creating a LinkedIn for clowns (a project still in the works mind you), but we soon settled on a better idea:

Ghostd: A Dating App for the deceased.

Sarah Ravencroft stans to the front

It was soon agreed that Henry would start the front-end while I would build out the back end in Ruby before joining him up front. We assumed it would be a pretty easy task, a few basic methods and a minor match function. A forty-eight hour adventure at most. To my shock, it turned about to rapidly balloon into an all-week affair creating complex interlocking methods and struggling with the restraints placed on me by the assignment rules. By week’s end, I wound up writing eleven application controller methods and another six model methods to handle the like, dislike, undo, response randomization, and reset functionality critical to our application. Strangest of all, I really enjoyed doing it. For the first time, coding actually felt like a fun puzzle, an exciting mystery to see just what the solution to each particular problem would be. It was stressful at times certainly, but overall the experience was exhilarating.

Other than my project partner, I didn’t really have a lot of help or resources to build out this relatively complex backend. Due to the specific limitations of our assignment (using only Ruby and SQLite) and the particular nature of our project, there weren’t many places I could go for exact answers. In the end I pretty much built out this extensive code on my own, and it did wonders for the confidence I have in my coding abilities.

Just be clear, I’m sure this is not very efficient code. I’m certain there are a million and a half better ways to do this an experienced professional would quickly see. Regardless though, for my first ever functional backend, I’m pretty proud of what I accomplished. Especially considering I’d never coded in my life a mere six months ago.

For both bragging and to assist anyone working on something even mildly close to this project, I thought I’d go over the most complex method I built for this project. The like function.

The Like Method in the App Controller
The Like Method in the Like Controller

We decided to base our project on dating apps like Tinder, with a stack of cards and a swiping function for liking and disliking profiles. The like function I had to construct on the backend needed to accomplish multiple tasks. First, it needed to determine if the profile that had been swiped on had interacted with the user. I created a randomization function to create a unique simulation of which ghosts had liked or disliked the user. If the ghost in question had, the interaction needed to be updated and a response sent to the frontend. If not, the interaction had to be generated and a different response sent to the frontend. Every quick swipe on the app either updated or created the database, regardless of whether or not the user saw it.

The response my partner and I decided to send back from the database was a boolean indicating whether or not the swipe was a match. If it was (ie. the randomization method selected “true” for the profile’s interaction), I sent down a true. This would trigger a matching pop-up module on the front end. If it didn’t, or the interaction was only just now generated, it returned a false.

Pictured: A very lucky man

This was only a basic summary of my like method, and there are many more methods I’m very proud of on the backend. If you’d like to see the full code, you can check it out on my github here: https://github.com/ScarlettEller1715/Ghosted-Backend

You can also check out the AMAZING front end my project partner Henry Miller constructed here: https://github.com/henreth/ghosted-frontend

He also discussed his perspective on the making of this app in his Medium post which you can find here: https://medium.com/@henr-eth/its-a-match-1ccd24730254

We’ll keep you updated for when the app is launched, and you can see which ghostly hotties you match with in the afterlife…

--

--