changed array notation for backwards compatibility; added getProfile method