diff options
Diffstat (limited to 'src/monoize.sml')
-rw-r--r-- | src/monoize.sml | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/monoize.sml b/src/monoize.sml index d0be7449..5e0e2599 100644 --- a/src/monoize.sml +++ b/src/monoize.sml @@ -3047,7 +3047,11 @@ fun monoExp (env, st, fm) (all as (e, loc)) = | ("Onunload", e, _) :: rest => findOnload (rest, onload, SOME e, acc) | x :: rest => findOnload (rest, onload, onunload, x :: acc) - val (onload, onunload, attrs) = findOnload (attrs, NONE, NONE, []) + val (onload, onunload, attrs) = + if tag = "body" then + findOnload (attrs, NONE, NONE, []) + else + (NONE, NONE, attrs) val (class, fm) = monoExp (env, st, fm) class val (dynClass, fm) = monoExp (env, st, fm) dynClass |