Make truncate_alert! method handle string keys

cc @sethk