update flyout template fn
Merge pull request #804 from blrm/flyoutfix

update flyout template fn