Cleaned up; this was not doing what I expected.