I actually ended up removing this function as it's not needed in this case