parameters: (osm_id, username, changeset_count, picture_url, email)
return_statement: return new_user
docstring: Creates user in DB
          :param osm_id: Unique OSM user id
          :param username: OSM Username
          :param changeset_count: OSM changeset count
docstring_summary: Creates user in DB
          :param osm_id: Unique OSM user id
          :param username: OSM Username
          :param changeset_count: OSM changeset count
docstring_tokens: Creates user in DB : param osm_id : Unique OSM user id : param username : OSM Username : param changeset_count : OSM changeset count
function: def register_user(osm_id, username, changeset_count, picture_url, email):
          """
          Creates user in DB
          :param osm_id: Unique OSM user id
          :param username: OSM Username
          :param changeset_count: OSM changeset count
          """
          new_user = User()
          new_user.id = osm_id
          new_user.username = username
          if picture_url is not None:
              new_user.picture_url = picture_url
  
          intermediate_level = current_app.config["MAPPER_LEVEL_INTERMEDIATE"]
          advanced_level = current_app.config["MAPPER_LEVEL_ADVANCED"]
  
          if changeset_count > advanced_level:
              new_user.mapping_level = MappingLevel.ADVANCED.value
          elif intermediate_level < changeset_count < advanced_level:
              new_user.mapping_level = MappingLevel.INTERMEDIATE.value
          else:
              new_user.mapping_level = MappingLevel.BEGINNER.value
  
          if email is not None:
              new_user.email_address = email
  
          new_user.create()
          return new_user
function_tokens: def register_user ( osm_id , username , changeset_count , picture_url , email ) : new_user = User ( ) new_user . id = osm_id new_user . username = username if picture_url is not None : new_user . picture_url = picture_url intermediate_level = current_app . config [ "MAPPER_LEVEL_INTERMEDIATE" ] advanced_level = current_app . config [ "MAPPER_LEVEL_ADVANCED" ] if changeset_count > advanced_level : new_user . mapping_level = MappingLevel . ADVANCED . value elif intermediate_level < changeset_count < advanced_level : new_user . mapping_level = MappingLevel . INTERMEDIATE . value else : new_user . mapping_level = MappingLevel . BEGINNER . value if email is not None : new_user . email_address = email new_user . create ( ) return new_user