fix dynamic use of fragment