I can't get the solution to work from this previous question and answer: Is it possible to mark designated entries in a bibliography with an asterisk?
Here is my example code:
\documentclass{article}
\usepackage[sorting=none, backend=biber]{biblatex} % load the package
\addbibresource{bibfilename.bib}
\begin{filecontents}{biblatex-dm.cfg}
\DeclareBibliographyCategory{asterisk}
\end{filecontents}
\addtocategory{asterisk}{key1, key2}
\renewbibmacro*{begentry}{\ifcategory{asterisk}{*\addspace}{}}
\begin{document}
\cite{key1}
\bibliography{bibfilename.bib}
\end{document}
And I get this error message:
What am I doing wrong?
