Photo-Fries rearrangement in different protein microenvironments