Fix an edge case for apps that modify their string prototype