Preheat the oven to 175°C/350°F. Place paper liners into the cupcake tin. In a microwaveable mixing bowl, combine butter and chopped chocolate and melt for 30 sec. in the microwave, or until the butter is completely melted. Whisk the chocolate until melted and smooth.
Add sugar, then eggs. Mix well until smooth. Sift cocoa and coffee powder into the mixture, add a part of the vanilla extract and rum, if desired, and whisk until combined. Spoon the batter into the cups about two-thirds full. Bake at 175°C/350°F for approx. 30 min. Take out and set aside for 5 min. Then remove cupcakes from the tin and continue to cool on a rack.
Use a fork to combine cream cheese, part of the vanilla extract, and confectioner’s sugar. Beat whipping cream until stiff peaks form. Gently fold in the cream cheese mixture. Put into the fridge for at least 30 min. before piping on the cupcakes.