fix a crach that happens randomly on view details