Spinning sprite

How would I make a sprite spin in place, one degree every frame?

function setup() 
    angle = 0
end

function draw() 
    background(0)
 
    angle = angle + 1

    translate(WIDTH / 2, HEIGHT / 2)
    rotate(angle) 
    sprite("Cargo Bot: Codea Logo", 0, 0)
end

I couldn’t get this to work, help?

The sprite name wasn’t correct, try this;

function setup() 
    angle = 0
end

function draw() 
    background(0, 0, 0, 255)

    angle = angle + 1
    translate(WIDTH / 2, HEIGHT / 2)
    rotate(angle) 
    sprite("Cargo Bot:Codea Icon", 0, 0)
end

@Mr_Ninja, @CNCode, sorry… I was on my computer so I took a guess for the sprite name.

Thank you!