Assets.absoluteFilePath gives Error: Assets is not defined

I have a server function that needs to get an asset from /private but I get the following error:

Assets is not defined

I’m using Meteor 3.1.2

function base64_encode(imgName) {
	const imgUrl = Assets.absoluteFilePath(imgName);
	return "data:image/gif;base64," + fs.readFileSync(imgUrl, 'base64');
}

I have created a Vue skeleton project with " meteor create AssetsTest --vue --release 3.1.2 " and to replicate the error if added a server function and Meteor call which uses the Assets.absoluteFilePath.

I have shared this project on GitHub: Meteor 3 AssetsTest