fix {frame} parsing error introduced in last commit
add frames flag validation