I bet you can take a photo while it’s still locked.
What phone is it?
I actually narrowly avoided this with an iPhone I found outside my block of flats – it was a hot day and after topping up the ‘leccy with a key i had already charged, I found an iphone on the way in.
Went upstairs, dropped the dressing gown as the flat was hot [“if in doubt get it out”] and looked over the phone.
Managed to activate the camera by prodding it, and realised I was looking at a great shot of my homunculus. Fumbled the thing in surprise and the camera went off, capturing only a blur of my carpet.
I returned it that night to the owner, the nice woman who lived with her daughter in the flat above; There would have been no way to delete the image without the passcode!!
I guess I would then have been one iPhone 4s up 😀