Attempt at removing regex