A bereaved mother has lost a legal battle to establish if she should have been consulted before police bailed a man arrested over the drug-related death of her teenage daughter.