Got an ugly solution working.