Skip to content

Commit

Permalink
Add comments
Browse files Browse the repository at this point in the history
  • Loading branch information
ikoenigsknecht committed Mar 11, 2024
1 parent 18306fe commit e62832a
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,13 @@ export const isGif = (buffer: Uint8Array): boolean => {
return false
}

/**
* Validate a profile photo in a user profile
*
* @param photoString Base64 string representing the photo file that was uploaded
* @param pubKey Public key string for logging purposes
* @returns True if photo is valid and false if not
*/
export const validatePhoto = (photoString: string, pubKey: string): boolean => {
// validate that we have the photo as a base64 string
if (typeof photoString !== 'string') {
Expand Down

0 comments on commit e62832a

Please sign in to comment.