fixed digest issue, moved strings to js