/* InstanceAccount.c generated by valac 0.56.19, the Vala compiler
 * generated from InstanceAccount.vala, do not modify */

#include <glib-object.h>
#include <gtk/gtk.h>
#include <json-glib/json-glib.h>
#include <glib.h>
#include <stdlib.h>
#include <string.h>
#include <gio/gio.h>
#include <gee.h>
#include <adwaita.h>
#include <libsoup/soup.h>
#include <glib/gi18n-lib.h>

#define TUBA_INSTANCE_ACCOUNT_EVENT_NEW_POST "update"
#define TUBA_INSTANCE_ACCOUNT_EVENT_EDIT_POST "status.update"
#define TUBA_INSTANCE_ACCOUNT_EVENT_DELETE_POST "delete"
#define TUBA_INSTANCE_ACCOUNT_EVENT_NOTIFICATION "notification"
#define TUBA_INSTANCE_ACCOUNT_EVENT_CONVERSATION "conversation"
#define TUBA_INSTANCE_ACCOUNT_EVENT_NOTIFICATIONS_MERGED "notifications_merged"
#define TUBA_INSTANCE_ACCOUNT_KIND_MENTION "mention"
#define TUBA_INSTANCE_ACCOUNT_KIND_REBLOG "reblog"
#define TUBA_INSTANCE_ACCOUNT_KIND_FAVOURITE "favourite"
#define TUBA_INSTANCE_ACCOUNT_KIND_FOLLOW "follow"
#define TUBA_INSTANCE_ACCOUNT_KIND_POLL "poll"
#define TUBA_INSTANCE_ACCOUNT_KIND_FOLLOW_REQUEST "follow_request"
#define TUBA_INSTANCE_ACCOUNT_KIND_REMOTE_REBLOG "__remote-reblog"
#define TUBA_INSTANCE_ACCOUNT_KIND_EDITED "update"
#define TUBA_INSTANCE_ACCOUNT_KIND_REPLY "tuba_reply"
#define TUBA_INSTANCE_ACCOUNT_KIND_SEVERED_RELATIONSHIPS "severed_relationships"
#define TUBA_INSTANCE_ACCOUNT_KIND_ADMIN_REPORT "admin.report"
#define TUBA_INSTANCE_ACCOUNT_KIND_ADMIN_SIGNUP "admin.sign_up"
#define TUBA_INSTANCE_ACCOUNT_KIND_STATUS "status"
#define TUBA_INSTANCE_ACCOUNT_KIND_PLEROMA_REACTION "pleroma:emoji_reaction"
#define TUBA_INSTANCE_ACCOUNT_KIND_REACTION "reaction"
#define TUBA_INSTANCE_ACCOUNT_KIND_ANNUAL_REPORT "annual_report"
#define TUBA_INSTANCE_ACCOUNT_KIND_MODERATION_WARNING "moderation_warning"
#define TUBA_INSTANCE_ACCOUNT_KIND_QUOTE "quote"
#define TUBA_INSTANCE_ACCOUNT_KIND_QUOTE_UPDATE "quoted_update"
#define TUBA_INSTANCE_ACCOUNT_KIND_COLLECTION_ADDED "added_to_collection"
#define TUBA_INSTANCE_ACCOUNT_KIND_COLLECTION_EDITED "collection_update"
#if !defined(VALA_STRICT_C)
#if !defined(__clang__) && defined(__GNUC__) && (__GNUC__ >= 14)
#pragma GCC diagnostic warning "-Wincompatible-pointer-types"
#elif defined(__clang__) && (__clang_major__ >= 16)
#pragma clang diagnostic ignored "-Wincompatible-function-pointer-types"
#pragma clang diagnostic ignored "-Wincompatible-pointer-types"
#endif
#endif
#if !defined(VALA_EXTERN)
#if defined(_MSC_VER)
#define VALA_EXTERN __declspec(dllexport) extern
#elif __GNUC__ >= 4
#define VALA_EXTERN __attribute__((visibility("default"))) extern
#else
#define VALA_EXTERN extern
#endif
#endif

#define TUBA_TYPE_WIDGETIZABLE (tuba_widgetizable_get_type ())
#define TUBA_WIDGETIZABLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_WIDGETIZABLE, TubaWidgetizable))
#define TUBA_IS_WIDGETIZABLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_WIDGETIZABLE))
#define TUBA_WIDGETIZABLE_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), TUBA_TYPE_WIDGETIZABLE, TubaWidgetizableIface))

typedef struct _TubaWidgetizable TubaWidgetizable;
typedef struct _TubaWidgetizableIface TubaWidgetizableIface;

#define TUBA_TYPE_ENTITY (tuba_entity_get_type ())
#define TUBA_ENTITY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_ENTITY, TubaEntity))
#define TUBA_ENTITY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_ENTITY, TubaEntityClass))
#define TUBA_IS_ENTITY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_ENTITY))
#define TUBA_IS_ENTITY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_ENTITY))
#define TUBA_ENTITY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_ENTITY, TubaEntityClass))

typedef struct _TubaEntity TubaEntity;
typedef struct _TubaEntityClass TubaEntityClass;

#define TUBA_API_TYPE_ACCOUNT (tuba_api_account_get_type ())
#define TUBA_API_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_ACCOUNT, TubaAPIAccount))
#define TUBA_API_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_ACCOUNT, TubaAPIAccountClass))
#define TUBA_API_IS_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_ACCOUNT))
#define TUBA_API_IS_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_ACCOUNT))
#define TUBA_API_ACCOUNT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_ACCOUNT, TubaAPIAccountClass))

typedef struct _TubaAPIAccount TubaAPIAccount;
typedef struct _TubaAPIAccountClass TubaAPIAccountClass;

#define TUBA_TYPE_INSTANCE_ACCOUNT (tuba_instance_account_get_type ())
#define TUBA_INSTANCE_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccount))
#define TUBA_INSTANCE_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccountClass))
#define TUBA_IS_INSTANCE_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_INSTANCE_ACCOUNT))
#define TUBA_IS_INSTANCE_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_INSTANCE_ACCOUNT))
#define TUBA_INSTANCE_ACCOUNT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccountClass))

typedef struct _TubaInstanceAccount TubaInstanceAccount;
typedef struct _TubaInstanceAccountClass TubaInstanceAccountClass;
typedef struct _TubaEntityPrivate TubaEntityPrivate;

#define TUBA_API_TYPE_SEARCH_RESULT (tuba_api_search_result_get_type ())
#define TUBA_API_SEARCH_RESULT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_SEARCH_RESULT, TubaAPISearchResult))
#define TUBA_API_IS_SEARCH_RESULT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_SEARCH_RESULT))
#define TUBA_API_SEARCH_RESULT_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), TUBA_API_TYPE_SEARCH_RESULT, TubaAPISearchResultIface))

typedef struct _TubaAPISearchResult TubaAPISearchResult;
typedef struct _TubaAPISearchResultIface TubaAPISearchResultIface;
typedef struct _TubaAPIAccountPrivate TubaAPIAccountPrivate;

#define TUBA_TYPE_STREAMABLE (tuba_streamable_get_type ())
#define TUBA_STREAMABLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_STREAMABLE, TubaStreamable))
#define TUBA_IS_STREAMABLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_STREAMABLE))
#define TUBA_STREAMABLE_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), TUBA_TYPE_STREAMABLE, TubaStreamableIface))

typedef struct _TubaStreamable TubaStreamable;
typedef struct _TubaStreamableIface TubaStreamableIface;
typedef struct _TubaInstanceAccountPrivate TubaInstanceAccountPrivate;

#define TUBA_INSTANCE_ACCOUNT_TYPE_KIND (tuba_instance_account_kind_get_type ())
typedef struct _TubaInstanceAccountKind TubaInstanceAccountKind;

#define TUBA_TYPE_PLACE (tuba_place_get_type ())
#define TUBA_PLACE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_PLACE, TubaPlace))
#define TUBA_PLACE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_PLACE, TubaPlaceClass))
#define TUBA_IS_PLACE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_PLACE))
#define TUBA_IS_PLACE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_PLACE))
#define TUBA_PLACE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_PLACE, TubaPlaceClass))

typedef struct _TubaPlace TubaPlace;
typedef struct _TubaPlaceClass TubaPlaceClass;

#define TUBA_API_TYPE_NOTIFICATION (tuba_api_notification_get_type ())
#define TUBA_API_NOTIFICATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_NOTIFICATION, TubaAPINotification))
#define TUBA_API_NOTIFICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_NOTIFICATION, TubaAPINotificationClass))
#define TUBA_API_IS_NOTIFICATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_NOTIFICATION))
#define TUBA_API_IS_NOTIFICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_NOTIFICATION))
#define TUBA_API_NOTIFICATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_NOTIFICATION, TubaAPINotificationClass))

typedef struct _TubaAPINotification TubaAPINotification;
typedef struct _TubaAPINotificationClass TubaAPINotificationClass;

#define TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY (tuba_instance_account_visibility_get_type ())
#define TUBA_INSTANCE_ACCOUNT_VISIBILITY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY, TubaInstanceAccountVisibility))
#define TUBA_INSTANCE_ACCOUNT_VISIBILITY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY, TubaInstanceAccountVisibilityClass))
#define TUBA_INSTANCE_ACCOUNT_IS_VISIBILITY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY))
#define TUBA_INSTANCE_ACCOUNT_IS_VISIBILITY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY))
#define TUBA_INSTANCE_ACCOUNT_VISIBILITY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY, TubaInstanceAccountVisibilityClass))

typedef struct _TubaInstanceAccountVisibility TubaInstanceAccountVisibility;
typedef struct _TubaInstanceAccountVisibilityClass TubaInstanceAccountVisibilityClass;
typedef enum  {
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_NONE = 1 << 0,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_QUOTE = 1 << 1,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_EMOJI_REACTIONS = 1 << 2,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_BUBBLE = 1 << 3,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GROUP_NOTIFICATIONS = 1 << 4,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_FEATURE_TAGS = 1 << 5,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ENDORSE_USERS = 1 << 6,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_MUTUALS = 1 << 7,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_TRANSLATION = 1 << 8,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ICESHRIMP = 1 << 9,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GLITCH = 1 << 10,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY = 1 << 11,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GOTOSOCIAL = 1 << 12
} TubaInstanceAccountInstanceFeatures;

#define TUBA_INSTANCE_ACCOUNT_TYPE_INSTANCE_FEATURES (tuba_instance_account_instance_features_get_type ())

#define TUBA_API_TYPE_INSTANCE (tuba_api_instance_get_type ())
#define TUBA_API_INSTANCE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_INSTANCE, TubaAPIInstance))
#define TUBA_API_INSTANCE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_INSTANCE, TubaAPIInstanceClass))
#define TUBA_API_IS_INSTANCE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_INSTANCE))
#define TUBA_API_IS_INSTANCE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_INSTANCE))
#define TUBA_API_INSTANCE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_INSTANCE, TubaAPIInstanceClass))

typedef struct _TubaAPIInstance TubaAPIInstance;
typedef struct _TubaAPIInstanceClass TubaAPIInstanceClass;

#define TUBA_API_TYPE_EMOJI (tuba_api_emoji_get_type ())
#define TUBA_API_EMOJI(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_EMOJI, TubaAPIEmoji))
#define TUBA_API_EMOJI_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_EMOJI, TubaAPIEmojiClass))
#define TUBA_API_IS_EMOJI(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_EMOJI))
#define TUBA_API_IS_EMOJI_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_EMOJI))
#define TUBA_API_EMOJI_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_EMOJI, TubaAPIEmojiClass))

typedef struct _TubaAPIEmoji TubaAPIEmoji;
typedef struct _TubaAPIEmojiClass TubaAPIEmojiClass;

#define TUBA_API_INSTANCE_V2_TYPE_API_VERSIONS (tuba_api_instance_v2_api_versions_get_type ())
#define TUBA_API_INSTANCE_V2_API_VERSIONS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_INSTANCE_V2_TYPE_API_VERSIONS, TubaAPIInstanceV2APIVersions))
#define TUBA_API_INSTANCE_V2_API_VERSIONS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_INSTANCE_V2_TYPE_API_VERSIONS, TubaAPIInstanceV2APIVersionsClass))
#define TUBA_API_INSTANCE_V2_IS_API_VERSIONS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_INSTANCE_V2_TYPE_API_VERSIONS))
#define TUBA_API_INSTANCE_V2_IS_API_VERSIONS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_INSTANCE_V2_TYPE_API_VERSIONS))
#define TUBA_API_INSTANCE_V2_API_VERSIONS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_INSTANCE_V2_TYPE_API_VERSIONS, TubaAPIInstanceV2APIVersionsClass))

typedef struct _TubaAPIInstanceV2APIVersions TubaAPIInstanceV2APIVersions;
typedef struct _TubaAPIInstanceV2APIVersionsClass TubaAPIInstanceV2APIVersionsClass;

#define TUBA_API_TYPE_ANNUAL_REPORTS (tuba_api_annual_reports_get_type ())
#define TUBA_API_ANNUAL_REPORTS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_ANNUAL_REPORTS, TubaAPIAnnualReports))
#define TUBA_API_ANNUAL_REPORTS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_ANNUAL_REPORTS, TubaAPIAnnualReportsClass))
#define TUBA_API_IS_ANNUAL_REPORTS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_ANNUAL_REPORTS))
#define TUBA_API_IS_ANNUAL_REPORTS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_ANNUAL_REPORTS))
#define TUBA_API_ANNUAL_REPORTS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_ANNUAL_REPORTS, TubaAPIAnnualReportsClass))

typedef struct _TubaAPIAnnualReports TubaAPIAnnualReports;
typedef struct _TubaAPIAnnualReportsClass TubaAPIAnnualReportsClass;
enum  {
	TUBA_INSTANCE_ACCOUNT_0_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_TUBA_INSTANCE_FEATURES_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_TUBA_ICESHRIMP_API_KEY_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_TUBA_STREAMING_URL_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_ADMIN_MODE_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_BACKEND_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_INFO_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_EMOJIS_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_CLIENT_ID_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_CLIENT_SECRET_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_ACCESS_TOKEN_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_NEEDS_UPDATE_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_TUBA_PROBABLY_HAS_NOTIFICATION_FILTERS_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_TUBA_REVOKED_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_TUBA_CRED_UPDATED_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_TUBA_VERIFIED_CREDENTIALS_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_TUBA_API_VERSIONS_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_HANDLE_SHORT_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_HANDLE_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_IS_ACTIVE_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_UUID_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_UNREVIEWED_FOLLOW_REQUESTS_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_UNREAD_ANNOUNCEMENTS_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_FILTERED_NOTIFICATIONS_COUNT_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_UNREAD_COUNT_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_LAST_READ_ID_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_LAST_RECEIVED_ID_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_TUBA_LAST_FEDIWRAPPED_YEAR_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_T_CONNECTION_URL_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_SUBSCRIBED_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_NUM_PROPERTIES
};
static GParamSpec* tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_NUM_PROPERTIES];
#define _g_free0(var) (var = (g_free (var), NULL))
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))

#define TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE (tuba_instance_account_status_content_type_get_type ())
#define TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentType))
#define TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentTypeClass))
#define TUBA_INSTANCE_ACCOUNT_IS_STATUS_CONTENT_TYPE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE))
#define TUBA_INSTANCE_ACCOUNT_IS_STATUS_CONTENT_TYPE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE))
#define TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentTypeClass))

typedef struct _TubaInstanceAccountStatusContentType TubaInstanceAccountStatusContentType;
typedef struct _TubaInstanceAccountStatusContentTypeClass TubaInstanceAccountStatusContentTypeClass;

#define TUBA_TYPE_SETTINGS (tuba_settings_get_type ())
#define TUBA_SETTINGS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_SETTINGS, TubaSettings))
#define TUBA_SETTINGS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_SETTINGS, TubaSettingsClass))
#define TUBA_IS_SETTINGS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_SETTINGS))
#define TUBA_IS_SETTINGS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_SETTINGS))
#define TUBA_SETTINGS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_SETTINGS, TubaSettingsClass))

typedef struct _TubaSettings TubaSettings;
typedef struct _TubaSettingsClass TubaSettingsClass;

#define TUBA_TYPE_ACCOUNT_STORE (tuba_account_store_get_type ())
#define TUBA_ACCOUNT_STORE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_ACCOUNT_STORE, TubaAccountStore))
#define TUBA_ACCOUNT_STORE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_ACCOUNT_STORE, TubaAccountStoreClass))
#define TUBA_IS_ACCOUNT_STORE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_ACCOUNT_STORE))
#define TUBA_IS_ACCOUNT_STORE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_ACCOUNT_STORE))
#define TUBA_ACCOUNT_STORE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_ACCOUNT_STORE, TubaAccountStoreClass))

typedef struct _TubaAccountStore TubaAccountStore;
typedef struct _TubaAccountStoreClass TubaAccountStoreClass;
#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))
#define _g_uri_unref0(var) ((var == NULL) ? NULL : (var = (g_uri_unref (var), NULL)))

#define TUBA_TYPE_APPLICATION (tuba_application_get_type ())
#define TUBA_APPLICATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_APPLICATION, TubaApplication))
#define TUBA_APPLICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_APPLICATION, TubaApplicationClass))
#define TUBA_IS_APPLICATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_APPLICATION))
#define TUBA_IS_APPLICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_APPLICATION))
#define TUBA_APPLICATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_APPLICATION, TubaApplicationClass))

typedef struct _TubaApplication TubaApplication;
typedef struct _TubaApplicationClass TubaApplicationClass;

#define TUBA_TYPE_STREAMS (tuba_streams_get_type ())
#define TUBA_STREAMS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_STREAMS, TubaStreams))
#define TUBA_STREAMS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_STREAMS, TubaStreamsClass))
#define TUBA_IS_STREAMS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_STREAMS))
#define TUBA_IS_STREAMS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_STREAMS))
#define TUBA_STREAMS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_STREAMS, TubaStreamsClass))

typedef struct _TubaStreams TubaStreams;
typedef struct _TubaStreamsClass TubaStreamsClass;

#define TUBA_TYPE_REQUEST_V2 (tuba_request_v2_get_type ())
#define TUBA_REQUEST_V2(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_REQUEST_V2, TubaRequestV2))
#define TUBA_REQUEST_V2_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_REQUEST_V2, TubaRequestV2Class))
#define TUBA_IS_REQUEST_V2(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_REQUEST_V2))
#define TUBA_IS_REQUEST_V2_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_REQUEST_V2))
#define TUBA_REQUEST_V2_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_REQUEST_V2, TubaRequestV2Class))

typedef struct _TubaRequestV2 TubaRequestV2;
typedef struct _TubaRequestV2Class TubaRequestV2Class;
typedef enum  {
	TUBA_REQUEST_V2_METHOD_GET,
	TUBA_REQUEST_V2_METHOD_POST,
	TUBA_REQUEST_V2_METHOD_PUT,
	TUBA_REQUEST_V2_METHOD_DELETE,
	TUBA_REQUEST_V2_METHOD_PATCH
} TubaRequestV2Method;

#define TUBA_REQUEST_V2_TYPE_METHOD (tuba_request_v2_method_get_type ())

#define TUBA_TYPE_OOPSIE (tuba_oopsie_get_type ())

#define TUBA_TYPE_NETWORK (tuba_network_get_type ())
#define TUBA_NETWORK(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_NETWORK, TubaNetwork))
#define TUBA_NETWORK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_NETWORK, TubaNetworkClass))
#define TUBA_IS_NETWORK(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_NETWORK))
#define TUBA_IS_NETWORK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_NETWORK))
#define TUBA_NETWORK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_NETWORK, TubaNetworkClass))

typedef struct _TubaNetwork TubaNetwork;
typedef struct _TubaNetworkClass TubaNetworkClass;
#define __vala_JsonNode_free0(var) ((var == NULL) ? NULL : (var = (_vala_JsonNode_free (var), NULL)))
typedef struct _TubaInstanceAccountOnNetworkChangeRealData TubaInstanceAccountOnNetworkChangeRealData;
typedef struct _TubaInstanceAccountVerifyCredentialsData TubaInstanceAccountVerifyCredentialsData;
typedef struct _TubaInstanceAccountUpdateObjectData TubaInstanceAccountUpdateObjectData;

#define TUBA_API_TYPE_SEARCH_RESULTS (tuba_api_search_results_get_type ())
#define TUBA_API_SEARCH_RESULTS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_SEARCH_RESULTS, TubaAPISearchResults))
#define TUBA_API_SEARCH_RESULTS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_SEARCH_RESULTS, TubaAPISearchResultsClass))
#define TUBA_API_IS_SEARCH_RESULTS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_SEARCH_RESULTS))
#define TUBA_API_IS_SEARCH_RESULTS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_SEARCH_RESULTS))
#define TUBA_API_SEARCH_RESULTS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_SEARCH_RESULTS, TubaAPISearchResultsClass))

typedef struct _TubaAPISearchResults TubaAPISearchResults;
typedef struct _TubaAPISearchResultsClass TubaAPISearchResultsClass;
typedef struct _TubaInstanceAccountResolveData TubaInstanceAccountResolveData;

#define TUBA_API_PLEROMA_TYPE_INSTANCE (tuba_api_pleroma_instance_get_type ())
#define TUBA_API_PLEROMA_INSTANCE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_PLEROMA_TYPE_INSTANCE, TubaAPIPleromaInstance))
#define TUBA_API_PLEROMA_INSTANCE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_PLEROMA_TYPE_INSTANCE, TubaAPIPleromaInstanceClass))
#define TUBA_API_PLEROMA_IS_INSTANCE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_PLEROMA_TYPE_INSTANCE))
#define TUBA_API_PLEROMA_IS_INSTANCE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_PLEROMA_TYPE_INSTANCE))
#define TUBA_API_PLEROMA_INSTANCE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_PLEROMA_TYPE_INSTANCE, TubaAPIPleromaInstanceClass))

typedef struct _TubaAPIPleromaInstance TubaAPIPleromaInstance;
typedef struct _TubaAPIPleromaInstanceClass TubaAPIPleromaInstanceClass;

#define TUBA_API_PLEROMA_INSTANCE_TYPE_METADATA (tuba_api_pleroma_instance_metadata_get_type ())
#define TUBA_API_PLEROMA_INSTANCE_METADATA(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_PLEROMA_INSTANCE_TYPE_METADATA, TubaAPIPleromaInstanceMetadata))
#define TUBA_API_PLEROMA_INSTANCE_METADATA_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_PLEROMA_INSTANCE_TYPE_METADATA, TubaAPIPleromaInstanceMetadataClass))
#define TUBA_API_PLEROMA_INSTANCE_IS_METADATA(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_PLEROMA_INSTANCE_TYPE_METADATA))
#define TUBA_API_PLEROMA_INSTANCE_IS_METADATA_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_PLEROMA_INSTANCE_TYPE_METADATA))
#define TUBA_API_PLEROMA_INSTANCE_METADATA_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_PLEROMA_INSTANCE_TYPE_METADATA, TubaAPIPleromaInstanceMetadataClass))

typedef struct _TubaAPIPleromaInstanceMetadata TubaAPIPleromaInstanceMetadata;
typedef struct _TubaAPIPleromaInstanceMetadataClass TubaAPIPleromaInstanceMetadataClass;

#define TUBA_API_INSTANCE_TYPE_URLS (tuba_api_instance_urls_get_type ())
#define TUBA_API_INSTANCE_URLS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_INSTANCE_TYPE_URLS, TubaAPIInstanceUrls))
#define TUBA_API_INSTANCE_URLS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_INSTANCE_TYPE_URLS, TubaAPIInstanceUrlsClass))
#define TUBA_API_INSTANCE_IS_URLS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_INSTANCE_TYPE_URLS))
#define TUBA_API_INSTANCE_IS_URLS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_INSTANCE_TYPE_URLS))
#define TUBA_API_INSTANCE_URLS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_INSTANCE_TYPE_URLS, TubaAPIInstanceUrlsClass))

typedef struct _TubaAPIInstanceUrls TubaAPIInstanceUrls;
typedef struct _TubaAPIInstanceUrlsClass TubaAPIInstanceUrlsClass;
typedef struct _TubaInstanceAccountGatherInstanceInfoData TubaInstanceAccountGatherInstanceInfoData;

#define TUBA_API_TYPE_INSTANCE_V2 (tuba_api_instance_v2_get_type ())
#define TUBA_API_INSTANCE_V2(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_INSTANCE_V2, TubaAPIInstanceV2))
#define TUBA_API_INSTANCE_V2_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_INSTANCE_V2, TubaAPIInstanceV2Class))
#define TUBA_API_IS_INSTANCE_V2(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_INSTANCE_V2))
#define TUBA_API_IS_INSTANCE_V2_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_INSTANCE_V2))
#define TUBA_API_INSTANCE_V2_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_INSTANCE_V2, TubaAPIInstanceV2Class))

typedef struct _TubaAPIInstanceV2 TubaAPIInstanceV2;
typedef struct _TubaAPIInstanceV2Class TubaAPIInstanceV2Class;

#define TUBA_API_INSTANCE_V2_TYPE_CONFIGURATION (tuba_api_instance_v2_configuration_get_type ())
#define TUBA_API_INSTANCE_V2_CONFIGURATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_INSTANCE_V2_TYPE_CONFIGURATION, TubaAPIInstanceV2Configuration))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_INSTANCE_V2_TYPE_CONFIGURATION, TubaAPIInstanceV2ConfigurationClass))
#define TUBA_API_INSTANCE_V2_IS_CONFIGURATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_INSTANCE_V2_TYPE_CONFIGURATION))
#define TUBA_API_INSTANCE_V2_IS_CONFIGURATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_INSTANCE_V2_TYPE_CONFIGURATION))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_INSTANCE_V2_TYPE_CONFIGURATION, TubaAPIInstanceV2ConfigurationClass))

typedef struct _TubaAPIInstanceV2Configuration TubaAPIInstanceV2Configuration;
typedef struct _TubaAPIInstanceV2ConfigurationClass TubaAPIInstanceV2ConfigurationClass;

#define TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_TRANSLATION (tuba_api_instance_v2_configuration_translation_get_type ())
#define TUBA_API_INSTANCE_V2_CONFIGURATION_TRANSLATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_TRANSLATION, TubaAPIInstanceV2ConfigurationTranslation))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_TRANSLATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_TRANSLATION, TubaAPIInstanceV2ConfigurationTranslationClass))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_IS_TRANSLATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_TRANSLATION))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_IS_TRANSLATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_TRANSLATION))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_TRANSLATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_TRANSLATION, TubaAPIInstanceV2ConfigurationTranslationClass))

typedef struct _TubaAPIInstanceV2ConfigurationTranslation TubaAPIInstanceV2ConfigurationTranslation;
typedef struct _TubaAPIInstanceV2ConfigurationTranslationClass TubaAPIInstanceV2ConfigurationTranslationClass;

#define TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_MEDIA_ATTACHMENTS (tuba_api_instance_v2_configuration_media_attachments_get_type ())
#define TUBA_API_INSTANCE_V2_CONFIGURATION_MEDIA_ATTACHMENTS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_MEDIA_ATTACHMENTS, TubaAPIInstanceV2ConfigurationMediaAttachments))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_MEDIA_ATTACHMENTS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_MEDIA_ATTACHMENTS, TubaAPIInstanceV2ConfigurationMediaAttachmentsClass))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_IS_MEDIA_ATTACHMENTS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_MEDIA_ATTACHMENTS))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_IS_MEDIA_ATTACHMENTS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_MEDIA_ATTACHMENTS))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_MEDIA_ATTACHMENTS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_MEDIA_ATTACHMENTS, TubaAPIInstanceV2ConfigurationMediaAttachmentsClass))

typedef struct _TubaAPIInstanceV2ConfigurationMediaAttachments TubaAPIInstanceV2ConfigurationMediaAttachments;
typedef struct _TubaAPIInstanceV2ConfigurationMediaAttachmentsClass TubaAPIInstanceV2ConfigurationMediaAttachmentsClass;

#define TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_ACCOUNTS_CHAR_LIMITS (tuba_api_instance_v2_configuration_accounts_char_limits_get_type ())
#define TUBA_API_INSTANCE_V2_CONFIGURATION_ACCOUNTS_CHAR_LIMITS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_ACCOUNTS_CHAR_LIMITS, TubaAPIInstanceV2ConfigurationAccountsCharLimits))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_ACCOUNTS_CHAR_LIMITS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_ACCOUNTS_CHAR_LIMITS, TubaAPIInstanceV2ConfigurationAccountsCharLimitsClass))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_IS_ACCOUNTS_CHAR_LIMITS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_ACCOUNTS_CHAR_LIMITS))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_IS_ACCOUNTS_CHAR_LIMITS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_ACCOUNTS_CHAR_LIMITS))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_ACCOUNTS_CHAR_LIMITS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_ACCOUNTS_CHAR_LIMITS, TubaAPIInstanceV2ConfigurationAccountsCharLimitsClass))

typedef struct _TubaAPIInstanceV2ConfigurationAccountsCharLimits TubaAPIInstanceV2ConfigurationAccountsCharLimits;
typedef struct _TubaAPIInstanceV2ConfigurationAccountsCharLimitsClass TubaAPIInstanceV2ConfigurationAccountsCharLimitsClass;
typedef struct _TubaInstanceAccountGatherV2InstanceInfoData TubaInstanceAccountGatherV2InstanceInfoData;
#define _g_time_zone_unref0(var) ((var == NULL) ? NULL : (var = (g_time_zone_unref (var), NULL)))
#define _g_date_time_unref0(var) ((var == NULL) ? NULL : (var = (g_date_time_unref (var), NULL)))

#define TUBA_API_ANNUAL_REPORTS_TYPE_REPORT (tuba_api_annual_reports_report_get_type ())
#define TUBA_API_ANNUAL_REPORTS_REPORT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_ANNUAL_REPORTS_TYPE_REPORT, TubaAPIAnnualReportsReport))
#define TUBA_API_ANNUAL_REPORTS_REPORT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_ANNUAL_REPORTS_TYPE_REPORT, TubaAPIAnnualReportsReportClass))
#define TUBA_API_ANNUAL_REPORTS_IS_REPORT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_ANNUAL_REPORTS_TYPE_REPORT))
#define TUBA_API_ANNUAL_REPORTS_IS_REPORT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_ANNUAL_REPORTS_TYPE_REPORT))
#define TUBA_API_ANNUAL_REPORTS_REPORT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_ANNUAL_REPORTS_TYPE_REPORT, TubaAPIAnnualReportsReportClass))

typedef struct _TubaAPIAnnualReportsReport TubaAPIAnnualReportsReport;
typedef struct _TubaAPIAnnualReportsReportClass TubaAPIAnnualReportsReportClass;
typedef struct _TubaInstanceAccountGatherAnnualReportData TubaInstanceAccountGatherAnnualReportData;
typedef struct _TubaInstanceAccountGatherInstanceCustomEmojisData TubaInstanceAccountGatherInstanceCustomEmojisData;

#define TUBA_DIALOGS_TYPE_MAIN_WINDOW (tuba_dialogs_main_window_get_type ())
#define TUBA_DIALOGS_MAIN_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_DIALOGS_TYPE_MAIN_WINDOW, TubaDialogsMainWindow))
#define TUBA_DIALOGS_MAIN_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_DIALOGS_TYPE_MAIN_WINDOW, TubaDialogsMainWindowClass))
#define TUBA_DIALOGS_IS_MAIN_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_DIALOGS_TYPE_MAIN_WINDOW))
#define TUBA_DIALOGS_IS_MAIN_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_DIALOGS_TYPE_MAIN_WINDOW))
#define TUBA_DIALOGS_MAIN_WINDOW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_DIALOGS_TYPE_MAIN_WINDOW, TubaDialogsMainWindowClass))

typedef struct _TubaDialogsMainWindow TubaDialogsMainWindow;
typedef struct _TubaDialogsMainWindowClass TubaDialogsMainWindowClass;

#define TUBA_VIEWS_TYPE_BASE (tuba_views_base_get_type ())
#define TUBA_VIEWS_BASE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_VIEWS_TYPE_BASE, TubaViewsBase))
#define TUBA_VIEWS_BASE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_VIEWS_TYPE_BASE, TubaViewsBaseClass))
#define TUBA_VIEWS_IS_BASE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_VIEWS_TYPE_BASE))
#define TUBA_VIEWS_IS_BASE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_VIEWS_TYPE_BASE))
#define TUBA_VIEWS_BASE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_VIEWS_TYPE_BASE, TubaViewsBaseClass))

typedef struct _TubaViewsBase TubaViewsBase;
typedef struct _TubaViewsBaseClass TubaViewsBaseClass;

#define TUBA_VIEWS_TYPE_CONTENT_BASE (tuba_views_content_base_get_type ())
#define TUBA_VIEWS_CONTENT_BASE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_VIEWS_TYPE_CONTENT_BASE, TubaViewsContentBase))
#define TUBA_VIEWS_CONTENT_BASE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_VIEWS_TYPE_CONTENT_BASE, TubaViewsContentBaseClass))
#define TUBA_VIEWS_IS_CONTENT_BASE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_VIEWS_TYPE_CONTENT_BASE))
#define TUBA_VIEWS_IS_CONTENT_BASE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_VIEWS_TYPE_CONTENT_BASE))
#define TUBA_VIEWS_CONTENT_BASE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_VIEWS_TYPE_CONTENT_BASE, TubaViewsContentBaseClass))

typedef struct _TubaViewsContentBase TubaViewsContentBase;
typedef struct _TubaViewsContentBaseClass TubaViewsContentBaseClass;

#define TUBA_VIEWS_TYPE_TIMELINE (tuba_views_timeline_get_type ())
#define TUBA_VIEWS_TIMELINE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_VIEWS_TYPE_TIMELINE, TubaViewsTimeline))
#define TUBA_VIEWS_TIMELINE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_VIEWS_TYPE_TIMELINE, TubaViewsTimelineClass))
#define TUBA_VIEWS_IS_TIMELINE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_VIEWS_TYPE_TIMELINE))
#define TUBA_VIEWS_IS_TIMELINE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_VIEWS_TYPE_TIMELINE))
#define TUBA_VIEWS_TIMELINE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_VIEWS_TYPE_TIMELINE, TubaViewsTimelineClass))

typedef struct _TubaViewsTimeline TubaViewsTimeline;
typedef struct _TubaViewsTimelineClass TubaViewsTimelineClass;

#define TUBA_VIEWS_TYPE_HASHTAG (tuba_views_hashtag_get_type ())
#define TUBA_VIEWS_HASHTAG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_VIEWS_TYPE_HASHTAG, TubaViewsHashtag))
#define TUBA_VIEWS_HASHTAG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_VIEWS_TYPE_HASHTAG, TubaViewsHashtagClass))
#define TUBA_VIEWS_IS_HASHTAG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_VIEWS_TYPE_HASHTAG))
#define TUBA_VIEWS_IS_HASHTAG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_VIEWS_TYPE_HASHTAG))
#define TUBA_VIEWS_HASHTAG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_VIEWS_TYPE_HASHTAG, TubaViewsHashtagClass))

typedef struct _TubaViewsHashtag TubaViewsHashtag;
typedef struct _TubaViewsHashtagClass TubaViewsHashtagClass;
typedef void (*TubaPlaceOpenFunc) (TubaDialogsMainWindow* window, GObject* extra);
typedef struct _Block49Data Block49Data;
typedef void (*TubaNetworkNodeCallback) (JsonNode* node, gpointer user_data, GError** error);

#define TUBA_API_TYPE_LIST (tuba_api_list_get_type ())
#define TUBA_API_LIST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_LIST, TubaAPIList))
#define TUBA_API_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_LIST, TubaAPIListClass))
#define TUBA_API_IS_LIST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_LIST))
#define TUBA_API_IS_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_LIST))
#define TUBA_API_LIST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_LIST, TubaAPIListClass))

typedef struct _TubaAPIList TubaAPIList;
typedef struct _TubaAPIListClass TubaAPIListClass;

#define TUBA_VIEWS_TYPE_LIST (tuba_views_list_get_type ())
#define TUBA_VIEWS_LIST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_VIEWS_TYPE_LIST, TubaViewsList))
#define TUBA_VIEWS_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_VIEWS_TYPE_LIST, TubaViewsListClass))
#define TUBA_VIEWS_IS_LIST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_VIEWS_TYPE_LIST))
#define TUBA_VIEWS_IS_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_VIEWS_TYPE_LIST))
#define TUBA_VIEWS_LIST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_VIEWS_TYPE_LIST, TubaViewsListClass))

typedef struct _TubaViewsList TubaViewsList;
typedef struct _TubaViewsListClass TubaViewsListClass;
typedef struct _TubaInstanceAccountGatherFavListsData TubaInstanceAccountGatherFavListsData;
#define _json_array_unref0(var) ((var == NULL) ? NULL : (var = (json_array_unref (var), NULL)))
typedef struct _TubaInstanceAccountInitNotificationsData TubaInstanceAccountInitNotificationsData;
#define _json_object_unref0(var) ((var == NULL) ? NULL : (var = (json_object_unref (var), NULL)))
typedef struct _TubaInstanceAccountCheckNotificationsData TubaInstanceAccountCheckNotificationsData;
typedef struct _Block50Data Block50Data;
typedef struct _TubaInstanceAccountCheckAnnouncementsData TubaInstanceAccountCheckAnnouncementsData;
typedef struct _TubaInstanceAccountReadNotificationsData TubaInstanceAccountReadNotificationsData;
typedef struct _Block51Data Block51Data;

#define TUBA_API_TYPE_STATUS (tuba_api_status_get_type ())
#define TUBA_API_STATUS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_STATUS, TubaAPIStatus))
#define TUBA_API_STATUS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_STATUS, TubaAPIStatusClass))
#define TUBA_API_IS_STATUS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_STATUS))
#define TUBA_API_IS_STATUS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_STATUS))
#define TUBA_API_STATUS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_STATUS, TubaAPIStatusClass))

typedef struct _TubaAPIStatus TubaAPIStatus;
typedef struct _TubaAPIStatusClass TubaAPIStatusClass;

#define TUBA_STREAMABLE_TYPE_EVENT (tuba_streamable_event_get_type ())
typedef struct _TubaStreamableEvent TubaStreamableEvent;

#define TUBA_SETTINGS_TYPE_ACCOUNT (tuba_settings_account_get_type ())
#define TUBA_SETTINGS_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_SETTINGS_TYPE_ACCOUNT, TubaSettingsAccount))
#define TUBA_SETTINGS_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_SETTINGS_TYPE_ACCOUNT, TubaSettingsAccountClass))
#define TUBA_SETTINGS_IS_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_SETTINGS_TYPE_ACCOUNT))
#define TUBA_SETTINGS_IS_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_SETTINGS_TYPE_ACCOUNT))
#define TUBA_SETTINGS_ACCOUNT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_SETTINGS_TYPE_ACCOUNT, TubaSettingsAccountClass))

typedef struct _TubaSettingsAccount TubaSettingsAccount;
typedef struct _TubaSettingsAccountClass TubaSettingsAccountClass;
typedef struct _TubaInstanceAccountVisibilityPrivate TubaInstanceAccountVisibilityPrivate;
enum  {
	TUBA_INSTANCE_ACCOUNT_VISIBILITY_0_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_VISIBILITY_ID_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_VISIBILITY_NAME_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_VISIBILITY_ICON_NAME_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_VISIBILITY_DESCRIPTION_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_VISIBILITY_SMALL_ICON_NAME_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_VISIBILITY_NUM_PROPERTIES
};
static GParamSpec* tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_NUM_PROPERTIES];
typedef struct _TubaInstanceAccountStatusContentTypePrivate TubaInstanceAccountStatusContentTypePrivate;
enum  {
	TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_0_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_MIME_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_ICON_NAME_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_TITLE_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_SYNTAX_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_NUM_PROPERTIES
};
static GParamSpec* tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_NUM_PROPERTIES];
enum  {
	TUBA_INSTANCE_ACCOUNT_ACTIVATED_SIGNAL,
	TUBA_INSTANCE_ACCOUNT_DEACTIVATED_SIGNAL,
	TUBA_INSTANCE_ACCOUNT_ADDED_SIGNAL,
	TUBA_INSTANCE_ACCOUNT_REMOVED_SIGNAL,
	TUBA_INSTANCE_ACCOUNT_NUM_SIGNALS
};
static guint tuba_instance_account_signals[TUBA_INSTANCE_ACCOUNT_NUM_SIGNALS] = {0};

struct _TubaWidgetizableIface {
	GTypeInterface parent_iface;
	GtkWidget* (*to_widget) (TubaWidgetizable* self);
	void (*open) (TubaWidgetizable* self);
	void (*resolve_open) (TubaWidgetizable* self, TubaInstanceAccount* account);
};

struct _TubaEntity {
	GObject parent_instance;
	TubaEntityPrivate * priv;
};

struct _TubaEntityClass {
	GObjectClass parent_class;
	gboolean (*is_local) (TubaEntity* self, TubaInstanceAccount* account);
	GType (*deserialize_array_type) (TubaEntity* self, const gchar* prop);
};

struct _TubaAPISearchResultIface {
	GTypeInterface parent_iface;
	GRegex* (*get_tuba_search_query_regex) (TubaAPISearchResult* self);
	void (*set_tuba_search_query_regex) (TubaAPISearchResult* self, GRegex* value);
};

struct _TubaAPIAccount {
	TubaEntity parent_instance;
	TubaAPIAccountPrivate * priv;
};

struct _TubaAPIAccountClass {
	TubaEntityClass parent_class;
};

struct _TubaStreamableIface {
	GTypeInterface parent_iface;
	gchar* (*get_stream_url) (TubaStreamable* self);
	void (*on_streaming_policy_changed) (TubaStreamable* self);
	const gchar* (*get_t_connection_url) (TubaStreamable* self);
	void (*set_t_connection_url) (TubaStreamable* self, const gchar* value);
	gboolean (*get_subscribed) (TubaStreamable* self);
	void (*set_subscribed) (TubaStreamable* self, gboolean value);
};

struct _TubaInstanceAccountKind {
	gchar* icon;
	gchar* description;
	gchar* url;
};

struct _TubaInstanceAccount {
	TubaAPIAccount parent_instance;
	TubaInstanceAccountPrivate * priv;
	GListStore* known_places;
	GListStore* list_places;
	GListStore* tags_places;
	GeeHashMap* type_overrides;
	GeeHashMap* visibility;
	GListStore* visibility_list;
	GListStore* supported_mime_types;
};

struct _TubaInstanceAccountClass {
	TubaAPIAccountClass parent_class;
	void (*describe_kind) (TubaInstanceAccount* self, const gchar* kind, TubaInstanceAccountKind* _result_, const gchar* actor_name, const gchar* callback_url, const gchar* other_data);
	void (*register_known_places) (TubaInstanceAccount* self, GListStore* places);
	void (*register_extra) (TubaInstanceAccount* self, GListStore* places, TubaPlace** extra, gint extra_length1);
	void (*bump_sidebar_items) (TubaInstanceAccount* self);
	void (*check_notifications) (TubaInstanceAccount* self, GAsyncReadyCallback _callback_, gpointer _user_data_);
	void (*check_notifications_finish) (TubaInstanceAccount* self, GAsyncResult* _res_);
	gchar* (*get_stream_url) (TubaInstanceAccount* self);
	void (*on_notification_received) (TubaInstanceAccount* self, TubaAPINotification* entity);
	void (*open_status_url) (TubaInstanceAccount* self, const gchar* url);
	void (*answer_follow_request) (TubaInstanceAccount* self, const gchar* issuer_id, const gchar* fr_id, gboolean accept);
	void (*follow_back) (TubaInstanceAccount* self, const gchar* issuer_id, const gchar* acc_id);
	void (*reply_to_status_uri) (TubaInstanceAccount* self, const gchar* issuer_id, const gchar* uri);
	void (*remove_from_followers) (TubaInstanceAccount* self, const gchar* issuer_id, const gchar* acc_id);
	void (*activated) (TubaInstanceAccount* self);
	void (*deactivated) (TubaInstanceAccount* self);
	void (*added) (TubaInstanceAccount* self);
	void (*removed) (TubaInstanceAccount* self);
};

struct _TubaInstanceAccountPrivate {
	TubaInstanceAccountInstanceFeatures _tuba_instance_features;
	gchar* _tuba_iceshrimp_api_key;
	gchar* _tuba_streaming_url;
	gboolean _admin_mode;
	gchar* _backend;
	TubaAPIInstance* _instance_info;
	GeeArrayList* _instance_emojis;
	gchar* _instance;
	gchar* _client_id;
	gchar* _client_secret;
	gchar* _access_token;
	gboolean _needs_update;
	gboolean _tuba_probably_has_notification_filters;
	gboolean _tuba_revoked;
	gboolean _tuba_cred_updated;
	gboolean _tuba_verified_credentials;
	TubaAPIInstanceV2APIVersions* _tuba_api_versions;
	gchar* _uuid;
	gint _unreviewed_follow_requests;
	gint _unread_announcements;
	gint _filtered_notifications_count;
	gint _unread_count;
	gint _last_read_id;
	gint _last_received_id;
	gint _tuba_last_fediwrapped_year;
	TubaAPIAnnualReports* annual_report;
	GeeHashMap* sent_notifications;
	gchar* _t_connection_url;
	gboolean _subscribed;
	GSettings* _account_settings;
};

typedef enum  {
	TUBA_OOPSIE_USER,
	TUBA_OOPSIE_PARSING,
	TUBA_OOPSIE_INSTANCE,
	TUBA_OOPSIE_INTERNAL,
	TUBA_OOPSIE_HTTP_401 = 401,
	TUBA_OOPSIE_HTTP_403 = 403,
	TUBA_OOPSIE_HTTP_404 = 404,
	TUBA_OOPSIE_HTTP_410 = 410,
	TUBA_OOPSIE_HTTP_422 = 422,
	TUBA_OOPSIE_HTTP_429 = 429,
	TUBA_OOPSIE_HTTP_500 = 500,
	TUBA_OOPSIE_HTTP_503 = 503
} TubaOopsie;
#define TUBA_OOPSIE tuba_oopsie_quark ()

struct _TubaInstanceAccountOnNetworkChangeRealData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	TubaInstanceAccount* self;
	TubaRequestV2* req;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	gchar* _tmp3_;
	gchar* _tmp4_;
	TubaAccountStore* _tmp5_;
	TubaInstanceAccount* _tmp6_;
	TubaInstanceAccount* _tmp7_;
	TubaInstanceAccount* _tmp8_;
	TubaRequestV2* _tmp9_;
	TubaRequestV2* _tmp10_;
	GInputStream* in_stream;
	TubaRequestV2* _tmp11_;
	GInputStream* _tmp12_;
	JsonParser* parser;
	GInputStream* _tmp13_;
	JsonParser* _tmp14_;
	JsonNode* node;
	TubaNetwork* _tmp15_;
	JsonParser* _tmp16_;
	JsonNode* _tmp17_;
	JsonNode* _tmp18_;
	TubaAPIAccount* acc;
	JsonNode* _tmp19_;
	TubaAPIAccount* _tmp20_;
	gboolean _tmp21_;
	const gchar* _tmp22_;
	const gchar* _tmp23_;
	TubaAPIAccount* _tmp24_;
	const gchar* _tmp25_;
	const gchar* _tmp26_;
	const gchar* _tmp27_;
	const gchar* _tmp28_;
	TubaAPIAccount* _tmp29_;
	const gchar* _tmp30_;
	const gchar* _tmp31_;
	TubaAPIAccount* _tmp32_;
	const gchar* _tmp33_;
	const gchar* _tmp34_;
	TubaAPIAccount* _tmp35_;
	const gchar* _tmp36_;
	const gchar* _tmp37_;
	GError* e;
	const gchar* _tmp38_;
	const gchar* _tmp39_;
	const gchar* _tmp40_;
	GError* _tmp41_;
	gchar* _tmp42_;
	gchar* _tmp43_;
	GError* _tmp44_;
	const gchar* _tmp45_;
	const gchar* _tmp46_;
	gchar* _tmp47_;
	gchar* _tmp48_;
	GError* _inner_error0_;
};

struct _TubaInstanceAccountVerifyCredentialsData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	TubaInstanceAccount* self;
	TubaRequestV2* req;
	TubaInstanceAccount* _tmp0_;
	TubaRequestV2* _tmp1_;
	GInputStream* in_stream;
	TubaRequestV2* _tmp2_;
	GInputStream* _tmp3_;
	GInputStream* _tmp4_;
	GError* _inner_error0_;
};

struct _TubaInstanceAccountUpdateObjectData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	TubaInstanceAccount* self;
	GInputStream* in_stream;
	JsonParser* parser;
	JsonParser* _tmp0_;
	JsonNode* node;
	TubaNetwork* _tmp1_;
	JsonParser* _tmp2_;
	JsonNode* _tmp3_;
	TubaAPIAccount* updated;
	JsonNode* _tmp4_;
	TubaAPIAccount* _tmp5_;
	TubaAPIAccount* _tmp6_;
	gchar* _tmp7_;
	gchar* _tmp8_;
	gchar* _tmp9_;
	const gchar* _tmp10_;
	gchar* _tmp11_;
	gchar* _tmp12_;
	GError* _inner_error0_;
};

struct _TubaInstanceAccountResolveData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	TubaInstanceAccount* self;
	gchar* url;
	TubaEntity* result;
	const gchar* _tmp0_;
	gchar* _tmp1_;
	gchar* _tmp2_;
	TubaAPISearchResults* results;
	TubaAPISearchResults* _tmp3_;
	TubaEntity* entity;
	TubaAPISearchResults* _tmp4_;
	TubaEntity* _tmp5_;
	TubaEntity* _tmp6_;
	GObjectClass* _tmp7_;
	const gchar* _tmp8_;
	const gchar* _tmp9_;
	gchar* _tmp10_;
	gchar* _tmp11_;
	GError* _inner_error0_;
};

struct _TubaInstanceAccountGatherInstanceInfoData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	TubaInstanceAccount* self;
	TubaAPIInstance* _tmp0_;
	TubaRequestV2* req;
	TubaInstanceAccount* _tmp1_;
	TubaRequestV2* _tmp2_;
	GInputStream* in_stream;
	TubaRequestV2* _tmp3_;
	GInputStream* _tmp4_;
	JsonParser* parser;
	GInputStream* _tmp5_;
	JsonParser* _tmp6_;
	JsonNode* node;
	TubaNetwork* _tmp7_;
	JsonParser* _tmp8_;
	JsonNode* _tmp9_;
	JsonNode* _tmp10_;
	TubaAPIInstance* _tmp11_;
	JsonNode* _tmp12_;
	TubaAPIInstance* _tmp13_;
	gchar** content_types;
	TubaAPIInstance* _tmp14_;
	gchar** _tmp15_;
	gint _tmp15__length1;
	gint _tmp16_;
	gchar** _tmp17_;
	gint _tmp17__length1;
	gchar** _tmp18_;
	gint _tmp18__length1;
	gint content_types_length1;
	gint _content_types_size_;
	gchar** _tmp19_;
	gint _tmp19__length1;
	GListStore* _tmp20_;
	gchar** _tmp21_;
	gint _tmp21__length1;
	gchar** content_type_collection;
	gint content_type_collection_length1;
	gint _content_type_collection_size_;
	gint content_type_it;
	gchar* _tmp22_;
	gchar* content_type;
	GListStore* _tmp23_;
	const gchar* _tmp24_;
	TubaInstanceAccountStatusContentType* _tmp25_;
	TubaInstanceAccountStatusContentType* _tmp26_;
	TubaInstanceAccountInstanceFeatures new_flags;
	TubaInstanceAccountInstanceFeatures _tmp27_;
	gboolean _tmp28_;
	const gchar* _tmp29_;
	gchar* _tmp30_;
	gchar* _tmp31_;
	TubaAPIInstance* _tmp32_;
	TubaAPIPleromaInstance* _tmp33_;
	TubaAPIPleromaInstance* _tmp34_;
	gboolean _tmp35_;
	TubaAPIInstance* _tmp36_;
	TubaAPIPleromaInstance* _tmp37_;
	TubaAPIPleromaInstance* _tmp38_;
	TubaAPIPleromaInstanceMetadata* _tmp39_;
	TubaAPIPleromaInstanceMetadata* _tmp40_;
	TubaAPIInstance* _tmp41_;
	TubaAPIPleromaInstance* _tmp42_;
	TubaAPIPleromaInstance* _tmp43_;
	TubaAPIPleromaInstanceMetadata* _tmp44_;
	TubaAPIPleromaInstanceMetadata* _tmp45_;
	gchar** _tmp46_;
	gint _tmp46__length1;
	gint _tmp47_;
	gchar** _tmp48_;
	gint _tmp48__length1;
	TubaAPIInstance* _tmp49_;
	TubaAPIInstance* _tmp50_;
	TubaAPIPleromaInstance* _tmp51_;
	TubaAPIPleromaInstance* _tmp52_;
	TubaAPIPleromaInstanceMetadata* _tmp53_;
	TubaAPIPleromaInstanceMetadata* _tmp54_;
	gchar** _tmp55_;
	gint _tmp55__length1;
	gint _tmp56_;
	gchar** _tmp57_;
	gint _tmp57__length1;
	TubaInstanceAccountInstanceFeatures _tmp58_;
	TubaAPIInstance* _tmp59_;
	gboolean _tmp60_;
	gboolean _tmp61_;
	TubaInstanceAccountInstanceFeatures _tmp62_;
	TubaAPIInstance* _tmp63_;
	gboolean _tmp64_;
	gboolean _tmp65_;
	TubaAPIInstance* _tmp66_;
	gboolean _tmp67_;
	gboolean _tmp68_;
	gboolean _tmp69_;
	TubaAPIInstance* _tmp70_;
	const gchar* _tmp71_;
	const gchar* _tmp72_;
	TubaAPIInstance* _tmp73_;
	const gchar* _tmp74_;
	const gchar* _tmp75_;
	TubaAPIInstance* _tmp76_;
	const gchar* _tmp77_;
	const gchar* _tmp78_;
	TubaAPIInstance* _tmp79_;
	const gchar* _tmp80_;
	const gchar* _tmp81_;
	TubaAPIInstance* _tmp82_;
	const gchar* _tmp83_;
	const gchar* _tmp84_;
	TubaAPIInstance* _tmp85_;
	const gchar* _tmp86_;
	const gchar* _tmp87_;
	gboolean _tmp88_;
	TubaAPIInstance* _tmp89_;
	TubaAPIInstanceUrls* _tmp90_;
	TubaAPIInstanceUrls* _tmp91_;
	TubaAPIInstance* _tmp92_;
	TubaAPIInstanceUrls* _tmp93_;
	TubaAPIInstanceUrls* _tmp94_;
	const gchar* _tmp95_;
	const gchar* _tmp96_;
	TubaAPIInstance* _tmp97_;
	TubaAPIInstanceUrls* _tmp98_;
	TubaAPIInstanceUrls* _tmp99_;
	const gchar* _tmp100_;
	const gchar* _tmp101_;
	TubaApplication* _tmp102_;
	GError* e;
	GError* _tmp103_;
	gchar* _tmp104_;
	gchar* _tmp105_;
	GError* _tmp106_;
	const gchar* _tmp107_;
	const gchar* _tmp108_;
	gchar* _tmp109_;
	gchar* _tmp110_;
	GError* _inner_error0_;
};

struct _TubaInstanceAccountGatherV2InstanceInfoData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	TubaInstanceAccount* self;
	TubaRequestV2* req;
	TubaInstanceAccount* _tmp0_;
	TubaRequestV2* _tmp1_;
	GInputStream* in_stream;
	TubaRequestV2* _tmp2_;
	GInputStream* _tmp3_;
	JsonParser* parser;
	GInputStream* _tmp4_;
	JsonParser* _tmp5_;
	JsonNode* node;
	TubaNetwork* _tmp6_;
	JsonParser* _tmp7_;
	JsonNode* _tmp8_;
	JsonNode* _tmp9_;
	TubaInstanceAccountInstanceFeatures* new_flags;
	TubaAPIInstanceV2* instance_v2;
	JsonNode* _tmp10_;
	TubaAPIInstanceV2* _tmp11_;
	TubaAPIInstanceV2* _tmp12_;
	TubaInstanceAccountInstanceFeatures _tmp13_;
	TubaInstanceAccountInstanceFeatures* _tmp14_;
	TubaAPIInstanceV2* _tmp15_;
	TubaAPIInstanceV2Configuration* _tmp16_;
	TubaAPIInstanceV2Configuration* _tmp17_;
	TubaAPIInstanceV2* _tmp18_;
	TubaAPIInstanceV2Configuration* _tmp19_;
	TubaAPIInstanceV2Configuration* _tmp20_;
	TubaAPIInstanceV2ConfigurationTranslation* _tmp21_;
	TubaAPIInstanceV2ConfigurationTranslation* _tmp22_;
	TubaAPIInstance* _tmp23_;
	TubaAPIInstanceV2* _tmp24_;
	TubaAPIInstanceV2Configuration* _tmp25_;
	TubaAPIInstanceV2Configuration* _tmp26_;
	TubaAPIInstanceV2ConfigurationTranslation* _tmp27_;
	TubaAPIInstanceV2ConfigurationTranslation* _tmp28_;
	gboolean _tmp29_;
	gboolean _tmp30_;
	TubaAPIInstanceV2* _tmp31_;
	TubaAPIInstanceV2Configuration* _tmp32_;
	TubaAPIInstanceV2Configuration* _tmp33_;
	TubaAPIInstanceV2ConfigurationMediaAttachments* _tmp34_;
	TubaAPIInstanceV2ConfigurationMediaAttachments* _tmp35_;
	TubaAPIInstance* _tmp36_;
	TubaAPIInstanceV2* _tmp37_;
	TubaAPIInstanceV2Configuration* _tmp38_;
	TubaAPIInstanceV2Configuration* _tmp39_;
	TubaAPIInstanceV2ConfigurationMediaAttachments* _tmp40_;
	TubaAPIInstanceV2ConfigurationMediaAttachments* _tmp41_;
	gint64 _tmp42_;
	gint64 _tmp43_;
	TubaAPIInstanceV2* _tmp44_;
	TubaAPIInstanceV2Configuration* _tmp45_;
	TubaAPIInstanceV2Configuration* _tmp46_;
	TubaAPIInstanceV2ConfigurationAccountsCharLimits* _tmp47_;
	TubaAPIInstanceV2ConfigurationAccountsCharLimits* _tmp48_;
	TubaAPIInstance* _tmp49_;
	TubaAPIInstanceV2* _tmp50_;
	TubaAPIInstanceV2Configuration* _tmp51_;
	TubaAPIInstanceV2Configuration* _tmp52_;
	TubaAPIInstanceV2ConfigurationAccountsCharLimits* _tmp53_;
	TubaAPIInstanceV2ConfigurationAccountsCharLimits* _tmp54_;
	TubaInstanceAccountInstanceFeatures _tmp55_;
	TubaAPIInstance* _tmp56_;
	gboolean _tmp57_;
	gboolean _tmp58_;
	TubaInstanceAccountInstanceFeatures* _tmp59_;
	TubaInstanceAccountInstanceFeatures* _tmp60_;
	TubaInstanceAccountInstanceFeatures* _tmp61_;
	gboolean _tmp62_;
	TubaAPIInstanceV2* _tmp63_;
	TubaAPIInstanceV2APIVersions* _tmp64_;
	TubaAPIInstanceV2APIVersions* _tmp65_;
	TubaAPIInstanceV2* _tmp66_;
	TubaAPIInstanceV2APIVersions* _tmp67_;
	TubaAPIInstanceV2APIVersions* _tmp68_;
	gint8 _tmp69_;
	gint8 _tmp70_;
	TubaAPIInstanceV2APIVersions* _tmp71_;
	TubaAPIInstanceV2* _tmp72_;
	TubaAPIInstanceV2APIVersions* _tmp73_;
	TubaAPIInstanceV2APIVersions* _tmp74_;
	TubaAPIInstanceV2* _tmp75_;
	TubaAPIInstanceV2APIVersions* _tmp76_;
	TubaAPIInstanceV2APIVersions* _tmp77_;
	TubaAccountStore* _tmp78_;
	TubaAPIInstanceV2APIVersions* _tmp79_;
	gint8 _tmp80_;
	gint8 _tmp81_;
	TubaInstanceAccountInstanceFeatures* _tmp82_;
	TubaInstanceAccountInstanceFeatures _tmp83_;
	TubaInstanceAccountInstanceFeatures* _tmp84_;
	TubaAPIInstanceV2APIVersions* _tmp85_;
	gint8 _tmp86_;
	gint8 _tmp87_;
	TubaInstanceAccountInstanceFeatures* _tmp88_;
	TubaInstanceAccountInstanceFeatures _tmp89_;
	TubaInstanceAccountInstanceFeatures* _tmp90_;
	TubaAPIInstanceV2APIVersions* _tmp91_;
	gint8 _tmp92_;
	gint8 _tmp93_;
	TubaInstanceAccountInstanceFeatures* _tmp94_;
	TubaInstanceAccountInstanceFeatures _tmp95_;
	TubaInstanceAccountInstanceFeatures* _tmp96_;
	TubaAPIInstanceV2APIVersions* _tmp97_;
	gint8 _tmp98_;
	gint8 _tmp99_;
	TubaInstanceAccountInstanceFeatures* _tmp100_;
	TubaInstanceAccountInstanceFeatures _tmp101_;
	TubaInstanceAccountInstanceFeatures* _tmp102_;
	TubaInstanceAccountInstanceFeatures* _tmp103_;
	TubaInstanceAccountInstanceFeatures _tmp104_;
	TubaInstanceAccountInstanceFeatures* _tmp105_;
	TubaAPIInstance* _tmp106_;
	gboolean _tmp107_;
	gboolean _tmp108_;
	TubaInstanceAccountInstanceFeatures* _tmp109_;
	TubaInstanceAccountInstanceFeatures _tmp110_;
	TubaInstanceAccountInstanceFeatures* _tmp111_;
	TubaInstanceAccountInstanceFeatures* _tmp112_;
	TubaInstanceAccountInstanceFeatures* _tmp113_;
	GError* e;
	GError* _tmp114_;
	gchar* _tmp115_;
	gchar* _tmp116_;
	GError* _tmp117_;
	const gchar* _tmp118_;
	const gchar* _tmp119_;
	gchar* _tmp120_;
	gchar* _tmp121_;
	GError* _inner_error0_;
};

struct _TubaInstanceAccountGatherAnnualReportData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	TubaInstanceAccount* self;
	GDateTime* now;
	GTimeZone* _tmp0_;
	GTimeZone* _tmp1_;
	GDateTime* _tmp2_;
	GDateTime* _tmp3_;
	gint year;
	GDateTime* _tmp4_;
	GDateTime* _tmp5_;
	GDateTime* _tmp6_;
	TubaRequestV2* req;
	gchar* _tmp7_;
	gchar* _tmp8_;
	gchar* _tmp9_;
	gchar* _tmp10_;
	TubaInstanceAccount* _tmp11_;
	TubaRequestV2* _tmp12_;
	TubaRequestV2* _tmp13_;
	GInputStream* in_stream;
	TubaRequestV2* _tmp14_;
	GInputStream* _tmp15_;
	JsonParser* parser;
	GInputStream* _tmp16_;
	JsonParser* _tmp17_;
	JsonNode* node;
	TubaNetwork* _tmp18_;
	JsonParser* _tmp19_;
	JsonNode* _tmp20_;
	TubaAPIAnnualReports* _tmp21_;
	JsonNode* _tmp22_;
	TubaAPIAnnualReports* _tmp23_;
	TubaAPIAnnualReports* _tmp24_;
	TubaAPIAnnualReports* _tmp25_;
	GeeArrayList* _tmp26_;
	GeeArrayList* _tmp27_;
	gint _tmp28_;
	gint _tmp29_;
	GError* e;
	GError* _tmp30_;
	gchar* _tmp31_;
	gchar* _tmp32_;
	GError* _tmp33_;
	const gchar* _tmp34_;
	const gchar* _tmp35_;
	gchar* _tmp36_;
	gchar* _tmp37_;
	GError* _inner_error0_;
};

struct _TubaInstanceAccountGatherInstanceCustomEmojisData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	TubaInstanceAccount* self;
	GeeArrayList* _tmp0_;
	TubaRequestV2* req;
	TubaInstanceAccount* _tmp1_;
	TubaRequestV2* _tmp2_;
	GInputStream* in_stream;
	TubaRequestV2* _tmp3_;
	GInputStream* _tmp4_;
	JsonParser* parser;
	GInputStream* _tmp5_;
	JsonParser* _tmp6_;
	JsonNode* node;
	TubaNetwork* _tmp7_;
	JsonParser* _tmp8_;
	JsonNode* _tmp9_;
	JsonNode* _tmp10_;
	GValue res_emojis;
	JsonNode* _tmp11_;
	GValue _tmp12_;
	GValue _tmp13_;
	GError* e;
	GError* _tmp14_;
	gchar* _tmp15_;
	gchar* _tmp16_;
	GError* _tmp17_;
	const gchar* _tmp18_;
	const gchar* _tmp19_;
	gchar* _tmp20_;
	gchar* _tmp21_;
	GError* _inner_error0_;
};

struct _Block49Data {
	int _ref_count_;
	TubaInstanceAccount* self;
	TubaPlace** fav_lists;
	gint fav_lists_length1;
	gint _fav_lists_size_;
	gchar** all_ids;
	gint all_ids_length1;
	gint _all_ids_size_;
};

struct _TubaInstanceAccountGatherFavListsData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	TubaInstanceAccount* self;
	TubaSettings* _tmp0_;
	gchar** _tmp1_;
	gint _tmp1__length1;
	gint _tmp2_;
	gchar** _tmp3_;
	gint _tmp3__length1;
	GListStore* _tmp4_;
	TubaRequestV2* req;
	TubaInstanceAccount* _tmp5_;
	TubaRequestV2* _tmp6_;
	Block49Data* _data49_;
	GInputStream* in_stream;
	TubaRequestV2* _tmp7_;
	GInputStream* _tmp8_;
	JsonParser* parser;
	GInputStream* _tmp9_;
	JsonParser* _tmp10_;
	TubaPlace** _tmp11_;
	gchar** _tmp12_;
	JsonParser* _tmp13_;
	GListStore* _tmp14_;
	TubaPlace** _tmp15_;
	gint _tmp15__length1;
	gchar** new_favs;
	gchar** _tmp16_;
	gint new_favs_length1;
	gint _new_favs_size_;
	TubaSettings* _tmp17_;
	gchar** _tmp18_;
	gint _tmp18__length1;
	gint _tmp19_;
	gchar** _tmp20_;
	gint _tmp20__length1;
	gchar** fav_id_collection;
	gint fav_id_collection_length1;
	gint _fav_id_collection_size_;
	gint fav_id_it;
	gchar* _tmp21_;
	gchar* fav_id;
	const gchar* _tmp22_;
	gchar** _tmp23_;
	gint _tmp23__length1;
	const gchar* _tmp24_;
	gchar* _tmp25_;
	TubaSettings* _tmp26_;
	gchar** _tmp27_;
	gint _tmp27__length1;
	GError* e;
	GError* _tmp28_;
	gchar* _tmp29_;
	gchar* _tmp30_;
	GError* _tmp31_;
	const gchar* _tmp32_;
	const gchar* _tmp33_;
	gchar* _tmp34_;
	gchar* _tmp35_;
	GError* _inner_error0_;
};

struct _TubaInstanceAccountInitNotificationsData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	TubaInstanceAccount* self;
	TubaRequestV2* req;
	gchar* _tmp0_;
	gchar* _tmp1_;
	const gchar* _tmp2_;
	gchar* _tmp3_;
	gchar* _tmp4_;
	TubaInstanceAccount* _tmp5_;
	TubaRequestV2* _tmp6_;
	TubaRequestV2* _tmp7_;
	TubaRequestV2* _tmp8_;
	gint _tmp9_;
	gchar* _tmp10_;
	gchar* _tmp11_;
	GInputStream* in_stream;
	TubaRequestV2* _tmp12_;
	GInputStream* _tmp13_;
	JsonParser* parser;
	GInputStream* _tmp14_;
	JsonParser* _tmp15_;
	JsonArray* array;
	JsonParser* _tmp16_;
	JsonArray* _tmp17_;
	JsonArray* _tmp18_;
	JsonArray* _tmp19_;
	gint _tmp20_;
	JsonArray* _tmp21_;
	JsonObject* _tmp22_;
	const gchar* _tmp23_;
	GError* e;
	GError* _tmp24_;
	gchar* _tmp25_;
	gchar* _tmp26_;
	GError* _tmp27_;
	const gchar* _tmp28_;
	const gchar* _tmp29_;
	gchar* _tmp30_;
	gchar* _tmp31_;
	GError* _inner_error0_;
};

struct _TubaInstanceAccountCheckNotificationsData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	TubaInstanceAccount* self;
	TubaRequestV2* req;
	TubaInstanceAccount* _tmp0_;
	TubaRequestV2* _tmp1_;
	GInputStream* in_stream;
	TubaRequestV2* _tmp2_;
	GInputStream* _tmp3_;
	JsonParser* parser;
	GInputStream* _tmp4_;
	JsonParser* _tmp5_;
	JsonObject* root;
	TubaNetwork* _tmp6_;
	JsonParser* _tmp7_;
	JsonObject* _tmp8_;
	JsonObject* notifications;
	JsonObject* _tmp9_;
	JsonObject* _tmp10_;
	JsonObject* _tmp11_;
	const gchar* _tmp12_;
	GError* e;
	GError* _tmp13_;
	gchar* _tmp14_;
	gchar* _tmp15_;
	GError* _tmp16_;
	const gchar* _tmp17_;
	const gchar* _tmp18_;
	gchar* _tmp19_;
	gchar* _tmp20_;
	GError* _inner_error0_;
};

struct _Block50Data {
	int _ref_count_;
	TubaInstanceAccount* self;
	gint t_unread_announcements;
};

struct _TubaInstanceAccountCheckAnnouncementsData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	TubaInstanceAccount* self;
	TubaRequestV2* req;
	TubaInstanceAccount* _tmp0_;
	TubaRequestV2* _tmp1_;
	GInputStream* in_stream;
	TubaRequestV2* _tmp2_;
	GInputStream* _tmp3_;
	JsonParser* parser;
	GInputStream* _tmp4_;
	JsonParser* _tmp5_;
	JsonArray* array;
	JsonParser* _tmp6_;
	JsonArray* _tmp7_;
	JsonArray* _tmp8_;
	Block50Data* _data50_;
	JsonArray* _tmp9_;
	GError* e;
	GError* _tmp10_;
	gchar* _tmp11_;
	gchar* _tmp12_;
	GError* _tmp13_;
	const gchar* _tmp14_;
	const gchar* _tmp15_;
	gchar* _tmp16_;
	gchar* _tmp17_;
	GError* _inner_error0_;
};

struct _TubaInstanceAccountReadNotificationsData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	TubaInstanceAccount* self;
	gint up_to_id;
	gchar* _tmp0_;
	gchar* _tmp1_;
	gchar* _tmp2_;
	gchar* _tmp3_;
	gint _tmp4_;
	gint _tmp5_;
	TubaRequestV2* req;
	TubaInstanceAccount* _tmp6_;
	TubaRequestV2* _tmp7_;
	TubaRequestV2* _tmp8_;
	gchar* _tmp9_;
	gchar* _tmp10_;
	TubaRequestV2* _tmp11_;
	GInputStream* _tmp12_;
	GInputStream* _tmp13_;
	GError* e;
	GError* _tmp14_;
	gchar* _tmp15_;
	gchar* _tmp16_;
	GError* _tmp17_;
	const gchar* _tmp18_;
	const gchar* _tmp19_;
	gchar* _tmp20_;
	gchar* _tmp21_;
	gboolean _tmp22_;
	TubaAPIInstance* _tmp23_;
	TubaAPIInstance* _tmp24_;
	TubaAPIPleromaInstance* _tmp25_;
	TubaAPIPleromaInstance* _tmp26_;
	TubaInstanceAccount* _tmp27_;
	TubaRequestV2* _tmp28_;
	TubaRequestV2* _tmp29_;
	gchar* _tmp30_;
	gchar* _tmp31_;
	TubaRequestV2* _tmp32_;
	GInputStream* _tmp33_;
	GInputStream* _tmp34_;
	GError* _vala1_e;
	GError* _tmp35_;
	gchar* _tmp36_;
	gchar* _tmp37_;
	GError* _tmp38_;
	const gchar* _tmp39_;
	const gchar* _tmp40_;
	gchar* _tmp41_;
	gchar* _tmp42_;
	GeeIterator* _notification_id_it;
	GeeHashMap* _tmp43_;
	GeeSet* _tmp44_;
	GeeSet* _tmp45_;
	GeeSet* _tmp46_;
	GeeIterator* _tmp47_;
	GeeIterator* _tmp48_;
	GeeIterator* _tmp49_;
	gchar* notification_id;
	GeeIterator* _tmp50_;
	gpointer _tmp51_;
	TubaApplication* _tmp52_;
	const gchar* _tmp53_;
	GeeHashMap* _tmp54_;
	GError* _inner_error0_;
};

struct _Block51Data {
	int _ref_count_;
	TubaInstanceAccount* self;
	gchar* id;
	TubaAPINotification* obj;
};

struct _TubaStreamableEvent {
	gchar* type;
	JsonNode* payload;
};

struct _TubaInstanceAccountVisibility {
	GObject parent_instance;
	TubaInstanceAccountVisibilityPrivate * priv;
};

struct _TubaInstanceAccountVisibilityClass {
	GObjectClass parent_class;
};

struct _TubaInstanceAccountVisibilityPrivate {
	gchar* _id;
	gchar* _name;
	gchar* _icon_name;
	gchar* _description;
	gchar* _small_icon_name;
};

struct _TubaInstanceAccountStatusContentType {
	GObject parent_instance;
	TubaInstanceAccountStatusContentTypePrivate * priv;
};

struct _TubaInstanceAccountStatusContentTypeClass {
	GObjectClass parent_class;
};

struct _TubaInstanceAccountStatusContentTypePrivate {
	gchar* _mime;
	gchar* _icon_name;
	gchar* _title;
	gchar* _syntax;
};

static gint TubaInstanceAccount_private_offset;
static gpointer tuba_instance_account_parent_class = NULL;
VALA_EXTERN TubaSettings* tuba_settings;
VALA_EXTERN TubaAccountStore* tuba_accounts;
VALA_EXTERN TubaApplication* tuba_app;
VALA_EXTERN TubaNetwork* tuba_network;
static gint TubaInstanceAccountVisibility_private_offset;
static gpointer tuba_instance_account_visibility_parent_class = NULL;
static gint TubaInstanceAccountStatusContentType_private_offset;
static gpointer tuba_instance_account_status_content_type_parent_class = NULL;
VALA_EXTERN GEqualFunc tuba_instance_account_status_content_type_compare;
GEqualFunc tuba_instance_account_status_content_type_compare = NULL;
static TubaStreamableIface * tuba_instance_account_tuba_streamable_parent_iface = NULL;

VALA_EXTERN GType tuba_entity_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaEntity, g_object_unref)
VALA_EXTERN GType tuba_api_account_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIAccount, g_object_unref)
VALA_EXTERN GType tuba_instance_account_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaInstanceAccount, g_object_unref)
VALA_EXTERN GType tuba_widgetizable_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaWidgetizable, g_object_unref)
VALA_EXTERN GType tuba_api_search_result_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPISearchResult, g_object_unref)
VALA_EXTERN GType tuba_streamable_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaStreamable, g_object_unref)
VALA_EXTERN GType tuba_instance_account_kind_get_type (void) G_GNUC_CONST ;
VALA_EXTERN TubaInstanceAccountKind* tuba_instance_account_kind_dup (const TubaInstanceAccountKind* self);
VALA_EXTERN void tuba_instance_account_kind_free (TubaInstanceAccountKind* self);
VALA_EXTERN void tuba_instance_account_kind_copy (const TubaInstanceAccountKind* self,
                                      TubaInstanceAccountKind* dest);
VALA_EXTERN void tuba_instance_account_kind_destroy (TubaInstanceAccountKind* self);
G_DEFINE_AUTO_CLEANUP_CLEAR_FUNC (TubaInstanceAccountKind, tuba_instance_account_kind_destroy)
VALA_EXTERN GType tuba_place_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaPlace, g_object_unref)
VALA_EXTERN GType tuba_api_notification_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPINotification, g_object_unref)
VALA_EXTERN GType tuba_instance_account_visibility_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaInstanceAccountVisibility, g_object_unref)
VALA_EXTERN GType tuba_instance_account_instance_features_get_type (void) G_GNUC_CONST ;
VALA_EXTERN GType tuba_api_instance_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIInstance, g_object_unref)
VALA_EXTERN GType tuba_api_emoji_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIEmoji, g_object_unref)
VALA_EXTERN GType tuba_api_instance_v2_api_versions_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIInstanceV2APIVersions, g_object_unref)
VALA_EXTERN GType tuba_api_annual_reports_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIAnnualReports, g_object_unref)
VALA_EXTERN void tuba_instance_account_describe_kind (TubaInstanceAccount* self,
                                          const gchar* kind,
                                          TubaInstanceAccountKind* _result_,
                                          const gchar* actor_name,
                                          const gchar* callback_url,
                                          const gchar* other_data);
VALA_EXTERN void tuba_instance_account_register_known_places (TubaInstanceAccount* self,
                                                  GListStore* places);
VALA_EXTERN void tuba_instance_account_register_extra (TubaInstanceAccount* self,
                                           GListStore* places,
                                           TubaPlace** extra,
                                           gint extra_length1);
VALA_EXTERN void tuba_instance_account_bump_sidebar_items (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_check_notifications (TubaInstanceAccount* self,
                                                GAsyncReadyCallback _callback_,
                                                gpointer _user_data_);
VALA_EXTERN void tuba_instance_account_check_notifications_finish (TubaInstanceAccount* self,
                                                       GAsyncResult* _res_);
VALA_EXTERN gchar* tuba_instance_account_get_stream_url (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_on_notification_received (TubaInstanceAccount* self,
                                                     TubaAPINotification* entity);
VALA_EXTERN void tuba_instance_account_open_status_url (TubaInstanceAccount* self,
                                            const gchar* url);
VALA_EXTERN void tuba_instance_account_answer_follow_request (TubaInstanceAccount* self,
                                                  const gchar* issuer_id,
                                                  const gchar* fr_id,
                                                  gboolean accept);
VALA_EXTERN void tuba_instance_account_follow_back (TubaInstanceAccount* self,
                                        const gchar* issuer_id,
                                        const gchar* acc_id);
VALA_EXTERN void tuba_instance_account_reply_to_status_uri (TubaInstanceAccount* self,
                                                const gchar* issuer_id,
                                                const gchar* uri);
VALA_EXTERN void tuba_instance_account_remove_from_followers (TubaInstanceAccount* self,
                                                  const gchar* issuer_id,
                                                  const gchar* acc_id);
VALA_EXTERN void tuba_streamable_destruct_streamable (TubaStreamable* self);
VALA_EXTERN TubaAPIInstanceV2APIVersions* tuba_api_instance_v2_api_versions_new (void);
VALA_EXTERN TubaAPIInstanceV2APIVersions* tuba_api_instance_v2_api_versions_construct (GType object_type);
VALA_EXTERN GType tuba_instance_account_status_content_type_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaInstanceAccountStatusContentType, g_object_unref)
static void tuba_instance_account_tuba_instance_features_update_and_save (TubaInstanceAccount* self,
                                                                   TubaInstanceAccountInstanceFeatures features);
VALA_EXTERN TubaInstanceAccountInstanceFeatures tuba_instance_account_get_tuba_instance_features (TubaInstanceAccount* self);
VALA_EXTERN GType tuba_settings_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaSettings, g_object_unref)
VALA_EXTERN void tuba_instance_account_set_tuba_instance_features (TubaInstanceAccount* self,
                                                       TubaInstanceAccountInstanceFeatures value);
VALA_EXTERN GType tuba_account_store_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAccountStore, g_object_unref)
VALA_EXTERN void tuba_account_store_update_account (TubaAccountStore* self,
                                        TubaInstanceAccount* account,
                                        GError** error);
VALA_EXTERN const gchar* tuba_api_account_get_id (TubaAPIAccount* self);
VALA_EXTERN void tuba_instance_account_tuba_update_iceshrimp_api_key (TubaInstanceAccount* self,
                                                          const gchar* new_key);
VALA_EXTERN const gchar* tuba_instance_account_get_tuba_iceshrimp_api_key (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_tuba_iceshrimp_api_key (TubaInstanceAccount* self,
                                                       const gchar* value);
static void tuba_instance_account_tuba_update_streaming_url (TubaInstanceAccount* self,
                                                      const gchar* new_url);
VALA_EXTERN const gchar* tuba_instance_account_get_instance (TubaInstanceAccount* self);
VALA_EXTERN const gchar* tuba_instance_account_get_tuba_streaming_url (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_tuba_streaming_url (TubaInstanceAccount* self,
                                                   const gchar* value);
VALA_EXTERN GType tuba_application_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaApplication, g_object_unref)
VALA_EXTERN GType tuba_streams_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaStreams, g_object_unref)
VALA_EXTERN TubaStreams* tuba_application_get_app_streams (TubaApplication* self);
VALA_EXTERN void tuba_streams_upgrade (TubaStreams* self,
                           const gchar* old_url,
                           const gchar* new_url);
VALA_EXTERN void tuba_instance_account_reconnect (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_gather_instance_info (TubaInstanceAccount* self,
                                                 GAsyncReadyCallback _callback_,
                                                 gpointer _user_data_);
VALA_EXTERN void tuba_instance_account_gather_instance_info_finish (TubaInstanceAccount* self,
                                                        GAsyncResult* _res_);
VALA_EXTERN void tuba_instance_account_gather_instance_custom_emojis (TubaInstanceAccount* self,
                                                          GAsyncReadyCallback _callback_,
                                                          gpointer _user_data_);
VALA_EXTERN void tuba_instance_account_gather_instance_custom_emojis_finish (TubaInstanceAccount* self,
                                                                 GAsyncResult* _res_);
VALA_EXTERN void tuba_instance_account_gather_fav_lists (TubaInstanceAccount* self,
                                             GAsyncReadyCallback _callback_,
                                             gpointer _user_data_);
VALA_EXTERN void tuba_instance_account_gather_fav_lists_finish (TubaInstanceAccount* self,
                                                    GAsyncResult* _res_);
VALA_EXTERN gboolean tuba_instance_account_gather_fav_tags (TubaInstanceAccount* self);
static gboolean _tuba_instance_account_gather_fav_tags_gsource_func (gpointer self);
VALA_EXTERN void tuba_instance_account_check_announcements (TubaInstanceAccount* self,
                                                GAsyncReadyCallback _callback_,
                                                gpointer _user_data_);
VALA_EXTERN void tuba_instance_account_check_announcements_finish (TubaInstanceAccount* self,
                                                       GAsyncResult* _res_);
static void tuba_instance_account_on_network_change (TubaInstanceAccount* self);
VALA_EXTERN gboolean tuba_instance_account_get_is_active (TubaInstanceAccount* self);
VALA_EXTERN gboolean tuba_application_get_is_online (TubaApplication* self);
VALA_EXTERN TubaInstanceAccount* tuba_account_store_get_active (TubaAccountStore* self);
VALA_EXTERN gboolean tuba_instance_account_get_tuba_verified_credentials (TubaInstanceAccount* self);
VALA_EXTERN void tuba_account_store_verify_credentials (TubaAccountStore* self,
                                            TubaInstanceAccount* account,
                                            GAsyncReadyCallback _callback_,
                                            gpointer _user_data_);
VALA_EXTERN void tuba_account_store_verify_credentials_finish (TubaAccountStore* self,
                                                   GAsyncResult* _res_);
VALA_EXTERN gboolean tuba_instance_account_get_tuba_cred_updated (TubaInstanceAccount* self);
VALA_EXTERN void tuba_account_store_update_account_info (TubaAccountStore* self,
                                             TubaInstanceAccount* account,
                                             GAsyncReadyCallback _callback_,
                                             gpointer _user_data_);
VALA_EXTERN void tuba_account_store_update_account_info_finish (TubaAccountStore* self,
                                                    GAsyncResult* _res_);
VALA_EXTERN gboolean tuba_instance_account_get_needs_update (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_needs_update (TubaInstanceAccount* self,
                                             gboolean value);
static void tuba_instance_account_on_network_change_real (TubaInstanceAccount* self,
                                                   GAsyncReadyCallback _callback_,
                                                   gpointer _user_data_);
static void tuba_instance_account_on_network_change_real_finish (TubaInstanceAccount* self,
                                                          GAsyncResult* _res_);
static void tuba_instance_account_on_network_change_real_data_free (gpointer _data);
static gboolean tuba_instance_account_on_network_change_real_co (TubaInstanceAccountOnNetworkChangeRealData* _data_);
VALA_EXTERN GType tuba_request_v2_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaRequestV2, g_object_unref)
VALA_EXTERN GType tuba_request_v2_method_get_type (void) G_GNUC_CONST ;
VALA_EXTERN TubaRequestV2* tuba_request_v2_new (const gchar* url,
                                    TubaRequestV2Method method);
VALA_EXTERN TubaRequestV2* tuba_request_v2_construct (GType object_type,
                                          const gchar* url,
                                          TubaRequestV2Method method);
VALA_EXTERN void tuba_request_v2_set_account (TubaRequestV2* self,
                                  TubaInstanceAccount* value);
VALA_EXTERN void tuba_request_v2_exec (TubaRequestV2* self,
                           GAsyncReadyCallback _callback_,
                           gpointer _user_data_);
VALA_EXTERN GQuark tuba_oopsie_quark (void);
VALA_EXTERN GType tuba_oopsie_get_type (void) G_GNUC_CONST ;
VALA_EXTERN GInputStream* tuba_request_v2_exec_finish (TubaRequestV2* self,
                                           GAsyncResult* _res_,
                                           SoupMessageHeaders** response_headers,
                                           GError** error);
static void tuba_instance_account_on_network_change_real_ready (GObject* source_object,
                                                         GAsyncResult* _res_,
                                                         gpointer _user_data_);
VALA_EXTERN void tuba_network_get_parser_from_inputstream_async (GInputStream* in_stream,
                                                     GCancellable* cancellable,
                                                     GAsyncReadyCallback _callback_,
                                                     gpointer _user_data_);
VALA_EXTERN JsonParser* tuba_network_get_parser_from_inputstream_finish (GAsyncResult* _res_,
                                                             GError** error);
VALA_EXTERN GType tuba_network_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaNetwork, g_object_unref)
VALA_EXTERN JsonNode* tuba_network_parse_node (TubaNetwork* self,
                                   JsonParser* parser);
static void _vala_JsonNode_free (JsonNode* self);
VALA_EXTERN TubaAPIAccount* tuba_api_account_from (JsonNode* node,
                                       GError** error);
VALA_EXTERN const gchar* tuba_api_account_get_display_name (TubaAPIAccount* self);
VALA_EXTERN const gchar* tuba_api_account_get_avatar (TubaAPIAccount* self);
VALA_EXTERN void tuba_api_account_set_display_name (TubaAPIAccount* self,
                                        const gchar* value);
VALA_EXTERN void tuba_api_account_set_avatar (TubaAPIAccount* self,
                                  const gchar* value);
VALA_EXTERN TubaInstanceAccount* tuba_instance_account_new_empty (const gchar* instance);
VALA_EXTERN TubaInstanceAccount* tuba_instance_account_construct_empty (GType object_type,
                                                            const gchar* instance);
VALA_EXTERN void tuba_instance_account_set_visibility (TubaInstanceAccount* self,
                                           TubaInstanceAccountVisibility* obj);
VALA_EXTERN const gchar* tuba_instance_account_visibility_get_id (TubaInstanceAccountVisibility* self);
VALA_EXTERN gpointer tuba_instance_account_create_entity (TubaInstanceAccount* self,
                                              GType t_type,
                                              GBoxedCopyFunc t_dup_func,
                                              GDestroyNotify t_destroy_func,
                                              JsonNode* node,
                                              GError** error);
VALA_EXTERN TubaEntity* tuba_entity_from_json (GType type,
                                   JsonNode* node,
                                   GError** error);
VALA_EXTERN TubaEntity* tuba_instance_account_create_dynamic_entity (TubaInstanceAccount* self,
                                                         GType type,
                                                         JsonNode* node,
                                                         GError** error);
static void tuba_instance_account_verify_credentials_data_free (gpointer _data);
VALA_EXTERN void tuba_instance_account_verify_credentials (TubaInstanceAccount* self,
                                               GAsyncReadyCallback _callback_,
                                               gpointer _user_data_);
VALA_EXTERN void tuba_instance_account_verify_credentials_finish (TubaInstanceAccount* self,
                                                      GAsyncResult* _res_,
                                                      GError** error);
static gboolean tuba_instance_account_verify_credentials_co (TubaInstanceAccountVerifyCredentialsData* _data_);
static void tuba_instance_account_verify_credentials_ready (GObject* source_object,
                                                     GAsyncResult* _res_,
                                                     gpointer _user_data_);
VALA_EXTERN void tuba_instance_account_update_object (TubaInstanceAccount* self,
                                          GInputStream* in_stream,
                                          GAsyncReadyCallback _callback_,
                                          gpointer _user_data_);
VALA_EXTERN void tuba_instance_account_update_object_finish (TubaInstanceAccount* self,
                                                 GAsyncResult* _res_,
                                                 GError** error);
static void tuba_instance_account_update_object_data_free (gpointer _data);
static gboolean tuba_instance_account_update_object_co (TubaInstanceAccountUpdateObjectData* _data_);
static void tuba_instance_account_update_object_ready (GObject* source_object,
                                                GAsyncResult* _res_,
                                                gpointer _user_data_);
VALA_EXTERN void tuba_entity_patch (TubaEntity* self,
                        GObject* with);
VALA_EXTERN gchar* tuba_instance_account_get_handle (TubaInstanceAccount* self);
static void tuba_instance_account_resolve_data_free (gpointer _data);
VALA_EXTERN void tuba_instance_account_resolve (TubaInstanceAccount* self,
                                    const gchar* url,
                                    GAsyncReadyCallback _callback_,
                                    gpointer _user_data_);
VALA_EXTERN TubaEntity* tuba_instance_account_resolve_finish (TubaInstanceAccount* self,
                                                  GAsyncResult* _res_,
                                                  GError** error);
static gboolean tuba_instance_account_resolve_co (TubaInstanceAccountResolveData* _data_);
VALA_EXTERN GType tuba_api_search_results_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPISearchResults, g_object_unref)
VALA_EXTERN void tuba_api_search_results_request (const gchar* q,
                                      TubaInstanceAccount* account,
                                      GAsyncReadyCallback _callback_,
                                      gpointer _user_data_);
VALA_EXTERN TubaAPISearchResults* tuba_api_search_results_request_finish (GAsyncResult* _res_,
                                                              GError** error);
static void tuba_instance_account_resolve_ready (GObject* source_object,
                                          GAsyncResult* _res_,
                                          gpointer _user_data_);
VALA_EXTERN TubaEntity* tuba_api_search_results_first (TubaAPISearchResults* self,
                                           GError** error);
static void tuba_instance_account_real_describe_kind (TubaInstanceAccount* self,
                                               const gchar* kind,
                                               TubaInstanceAccountKind* _result_,
                                               const gchar* actor_name,
                                               const gchar* callback_url,
                                               const gchar* other_data);
static void tuba_instance_account_real_register_known_places (TubaInstanceAccount* self,
                                                       GListStore* places);
static void tuba_instance_account_real_register_extra (TubaInstanceAccount* self,
                                                GListStore* places,
                                                TubaPlace** extra,
                                                gint extra_length1);
static void tuba_instance_account_gather_instance_info_data_free (gpointer _data);
static gboolean tuba_instance_account_gather_instance_info_co (TubaInstanceAccountGatherInstanceInfoData* _data_);
VALA_EXTERN TubaAPIInstance* tuba_instance_account_get_instance_info (TubaInstanceAccount* self);
static void tuba_instance_account_gather_instance_info_ready (GObject* source_object,
                                                       GAsyncResult* _res_,
                                                       gpointer _user_data_);
VALA_EXTERN TubaAPIInstance* tuba_api_instance_from (JsonNode* node,
                                         GError** error);
VALA_EXTERN void tuba_instance_account_set_instance_info (TubaInstanceAccount* self,
                                              TubaAPIInstance* value);
VALA_EXTERN gchar** tuba_api_instance_get_compat_supported_mime_types (TubaAPIInstance* self,
                                                           gint* result_length1);
static gchar** _vala_array_dup34 (gchar** self,
                           gssize length);
VALA_EXTERN TubaInstanceAccountStatusContentType* tuba_instance_account_status_content_type_new (const gchar* content_type);
VALA_EXTERN TubaInstanceAccountStatusContentType* tuba_instance_account_status_content_type_construct (GType object_type,
                                                                                           const gchar* content_type);
VALA_EXTERN const gchar* tuba_instance_account_get_backend (TubaInstanceAccount* self);
VALA_EXTERN GType tuba_api_pleroma_instance_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIPleromaInstance, g_object_unref)
VALA_EXTERN TubaAPIPleromaInstance* tuba_api_instance_get_pleroma (TubaAPIInstance* self);
static void tuba_instance_account_gather_v2_instance_info (TubaInstanceAccount* self,
                                                    GAsyncReadyCallback _callback_,
                                                    gpointer _user_data_);
static void tuba_instance_account_gather_v2_instance_info_finish (TubaInstanceAccount* self,
                                                           GAsyncResult* _res_);
VALA_EXTERN GType tuba_api_pleroma_instance_metadata_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIPleromaInstanceMetadata, g_object_unref)
VALA_EXTERN TubaAPIPleromaInstanceMetadata* tuba_api_pleroma_instance_get_metadata (TubaAPIPleromaInstance* self);
VALA_EXTERN gchar** tuba_api_pleroma_instance_metadata_get_features (TubaAPIPleromaInstanceMetadata* self,
                                                         gint* result_length1);
static gboolean _vala_string_array_contains (gchar* * stack,
                                      gssize stack_length,
                                      const gchar* needle);
VALA_EXTERN void tuba_api_instance_set_tuba_can_translate (TubaAPIInstance* self,
                                               gboolean value);
VALA_EXTERN gboolean tuba_api_instance_get_supports_quote_posting (TubaAPIInstance* self);
VALA_EXTERN gboolean tuba_api_instance_get_tuba_can_translate (TubaAPIInstance* self);
VALA_EXTERN gboolean tuba_api_instance_get_supports_bubble (TubaAPIInstance* self);
VALA_EXTERN const gchar* tuba_api_instance_get_version (TubaAPIInstance* self);
VALA_EXTERN GType tuba_api_instance_urls_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIInstanceUrls, g_object_unref)
VALA_EXTERN TubaAPIInstanceUrls* tuba_api_instance_get_urls (TubaAPIInstance* self);
VALA_EXTERN const gchar* tuba_api_instance_urls_get_streaming_api (TubaAPIInstanceUrls* self);
VALA_EXTERN void tuba_application_handle_share (TubaApplication* self);
static void tuba_instance_account_real_bump_sidebar_items (TubaInstanceAccount* self);
static void tuba_instance_account_gather_v2_instance_info_data_free (gpointer _data);
static gboolean tuba_instance_account_gather_v2_instance_info_co (TubaInstanceAccountGatherV2InstanceInfoData* _data_);
static void tuba_instance_account_gather_v2_instance_info_ready (GObject* source_object,
                                                          GAsyncResult* _res_,
                                                          gpointer _user_data_);
VALA_EXTERN GType tuba_api_instance_v2_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIInstanceV2, g_object_unref)
VALA_EXTERN TubaAPIInstanceV2* tuba_api_instance_v2_from (JsonNode* node,
                                              GError** error);
static TubaInstanceAccountInstanceFeatures* _tuba_instance_account_instance_features_dup (TubaInstanceAccountInstanceFeatures* self);
VALA_EXTERN GType tuba_api_instance_v2_configuration_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIInstanceV2Configuration, g_object_unref)
VALA_EXTERN TubaAPIInstanceV2Configuration* tuba_api_instance_v2_get_configuration (TubaAPIInstanceV2* self);
VALA_EXTERN GType tuba_api_instance_v2_configuration_translation_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIInstanceV2ConfigurationTranslation, g_object_unref)
VALA_EXTERN TubaAPIInstanceV2ConfigurationTranslation* tuba_api_instance_v2_configuration_get_translation (TubaAPIInstanceV2Configuration* self);
VALA_EXTERN gboolean tuba_api_instance_v2_configuration_translation_get_enabled (TubaAPIInstanceV2ConfigurationTranslation* self);
VALA_EXTERN GType tuba_api_instance_v2_configuration_media_attachments_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIInstanceV2ConfigurationMediaAttachments, g_object_unref)
VALA_EXTERN TubaAPIInstanceV2ConfigurationMediaAttachments* tuba_api_instance_v2_configuration_get_media_attachments (TubaAPIInstanceV2Configuration* self);
VALA_EXTERN gint64 tuba_api_instance_v2_configuration_media_attachments_get_description_limit (TubaAPIInstanceV2ConfigurationMediaAttachments* self);
VALA_EXTERN void tuba_api_instance_set_tuba_max_alt_chars (TubaAPIInstance* self,
                                               gint64 value);
VALA_EXTERN GType tuba_api_instance_v2_configuration_accounts_char_limits_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIInstanceV2ConfigurationAccountsCharLimits, g_object_unref)
VALA_EXTERN TubaAPIInstanceV2ConfigurationAccountsCharLimits* tuba_api_instance_v2_configuration_get_accounts (TubaAPIInstanceV2Configuration* self);
VALA_EXTERN void tuba_api_instance_set_tuba_limits (TubaAPIInstance* self,
                                        TubaAPIInstanceV2ConfigurationAccountsCharLimits* value);
VALA_EXTERN TubaAPIInstanceV2APIVersions* tuba_api_instance_v2_get_api_versions (TubaAPIInstanceV2* self);
VALA_EXTERN gint8 tuba_api_instance_v2_api_versions_get_mastodon (TubaAPIInstanceV2APIVersions* self);
VALA_EXTERN TubaAPIInstanceV2APIVersions* tuba_instance_account_get_tuba_api_versions (TubaInstanceAccount* self);
VALA_EXTERN gboolean tuba_api_instance_v2_api_versions_tuba_same (TubaAPIInstanceV2APIVersions* self,
                                                      TubaAPIInstanceV2APIVersions* new_val);
VALA_EXTERN void tuba_instance_account_set_tuba_api_versions (TubaInstanceAccount* self,
                                                  TubaAPIInstanceV2APIVersions* value);
VALA_EXTERN void tuba_instance_account_set_tuba_probably_has_notification_filters (TubaInstanceAccount* self,
                                                                       gboolean value);
static void tuba_instance_account_gather_annual_report (TubaInstanceAccount* self,
                                                 GAsyncReadyCallback _callback_,
                                                 gpointer _user_data_);
static void tuba_instance_account_gather_annual_report_finish (TubaInstanceAccount* self,
                                                        GAsyncResult* _res_);
VALA_EXTERN gint8 tuba_api_instance_v2_api_versions_get_chuckya (TubaAPIInstanceV2APIVersions* self);
static void tuba_instance_account_gather_annual_report_data_free (gpointer _data);
static gboolean tuba_instance_account_gather_annual_report_co (TubaInstanceAccountGatherAnnualReportData* _data_);
static void tuba_instance_account_gather_annual_report_ready (GObject* source_object,
                                                       GAsyncResult* _res_,
                                                       gpointer _user_data_);
VALA_EXTERN TubaAPIAnnualReports* tuba_api_annual_reports_from (JsonNode* node,
                                                    GError** error);
VALA_EXTERN GType tuba_api_annual_reports_report_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIAnnualReportsReport, g_object_unref)
VALA_EXTERN GeeArrayList* tuba_api_annual_reports_get_annual_reports (TubaAPIAnnualReports* self);
VALA_EXTERN void tuba_instance_account_set_tuba_last_fediwrapped_year (TubaInstanceAccount* self,
                                                           gint value);
VALA_EXTERN void tuba_instance_account_open_latest_wrapped (TubaInstanceAccount* self);
VALA_EXTERN gint tuba_instance_account_get_tuba_last_fediwrapped_year (TubaInstanceAccount* self);
VALA_EXTERN void tuba_api_annual_reports_open (TubaAPIAnnualReports* self,
                                   gint year);
static void tuba_instance_account_gather_instance_custom_emojis_data_free (gpointer _data);
static gboolean tuba_instance_account_gather_instance_custom_emojis_co (TubaInstanceAccountGatherInstanceCustomEmojisData* _data_);
VALA_EXTERN GeeArrayList* tuba_instance_account_get_instance_emojis (TubaInstanceAccount* self);
static void tuba_instance_account_gather_instance_custom_emojis_ready (GObject* source_object,
                                                                GAsyncResult* _res_,
                                                                gpointer _user_data_);
VALA_EXTERN gboolean tuba_entity_des_list (GValue* val,
                               JsonNode* node,
                               GType type);
VALA_EXTERN void tuba_instance_account_set_instance_emojis (TubaInstanceAccount* self,
                                                GeeArrayList* value);
VALA_EXTERN gchar** tuba_settings_get_favorite_tags_ids (TubaSettings* self,
                                             gint* result_length1);
VALA_EXTERN GType tuba_dialogs_main_window_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaDialogsMainWindow, g_object_unref)
static void ____lambda41_ (TubaDialogsMainWindow* win,
                    GObject* tag_obj);
VALA_EXTERN GType tuba_views_base_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaViewsBase, g_object_unref)
VALA_EXTERN TubaViewsBase* tuba_dialogs_main_window_open_view (TubaDialogsMainWindow* self,
                                                   TubaViewsBase* view);
VALA_EXTERN TubaViewsBase* tuba_instance_account_set_as_sidebar_item (TubaViewsBase* view);
VALA_EXTERN TubaViewsHashtag* tuba_views_hashtag_new (const gchar* tag,
                                          gboolean* following,
                                          const gchar* url_basename,
                                          gboolean* featured);
VALA_EXTERN TubaViewsHashtag* tuba_views_hashtag_construct (GType object_type,
                                                const gchar* tag,
                                                gboolean* following,
                                                const gchar* url_basename,
                                                gboolean* featured);
VALA_EXTERN GType tuba_views_content_base_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaViewsContentBase, g_object_unref)
VALA_EXTERN GType tuba_views_timeline_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaViewsTimeline, g_object_unref)
VALA_EXTERN GType tuba_views_hashtag_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaViewsHashtag, g_object_unref)
VALA_EXTERN void tuba_application_load_egg (TubaApplication* self,
                                const gchar* style);
static void _____lambda41__tuba_place_open_func (TubaDialogsMainWindow* window,
                                          GObject* extra);
VALA_EXTERN TubaPlace* tuba_place_new (void);
VALA_EXTERN TubaPlace* tuba_place_construct (GType object_type);
VALA_EXTERN void tuba_place_set_icon (TubaPlace* self,
                          const gchar* value);
VALA_EXTERN void tuba_place_set_title (TubaPlace* self,
                           const gchar* value);
VALA_EXTERN void tuba_place_set_extra_data (TubaPlace* self,
                                GObject* value);
VALA_EXTERN void tuba_place_set_open_func (TubaPlace* self,
                               TubaPlaceOpenFunc value);
static void _vala_array_add50 (TubaPlace** * array,
                        gint* length,
                        gint* size,
                        TubaPlace* value);
static void tuba_instance_account_gather_fav_lists_data_free (gpointer _data);
static gboolean tuba_instance_account_gather_fav_lists_co (TubaInstanceAccountGatherFavListsData* _data_);
VALA_EXTERN gchar** tuba_settings_get_favorite_lists_ids (TubaSettings* self,
                                              gint* result_length1);
static Block49Data* block49_data_ref (Block49Data* _data49_);
static void block49_data_unref (void * _userdata_);
static void tuba_instance_account_gather_fav_lists_ready (GObject* source_object,
                                                   GAsyncResult* _res_,
                                                   gpointer _user_data_);
VALA_EXTERN void tuba_network_parse_array (JsonParser* parser,
                               TubaNetworkNodeCallback cb,
                               gpointer cb_target,
                               GDestroyNotify cb_target_destroy_notify,
                               GError** error);
static void ___lambda156_ (Block49Data* _data49_,
                    JsonNode* node,
                    GError** error);
VALA_EXTERN GType tuba_api_list_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIList, g_object_unref)
VALA_EXTERN TubaAPIList* tuba_api_list_from (JsonNode* node,
                                 GError** error);
VALA_EXTERN const gchar* tuba_api_list_get_id (TubaAPIList* self);
VALA_EXTERN const gchar* tuba_api_list_get_title (TubaAPIList* self);
static void ___lambda157_ (TubaDialogsMainWindow* win,
                    GObject* list);
VALA_EXTERN TubaViewsList* tuba_views_list_new (TubaAPIList* l);
VALA_EXTERN TubaViewsList* tuba_views_list_construct (GType object_type,
                                          TubaAPIList* l);
VALA_EXTERN GType tuba_views_list_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaViewsList, g_object_unref)
static void ____lambda157__tuba_place_open_func (TubaDialogsMainWindow* window,
                                          GObject* extra);
static void _vala_array_add51 (TubaPlace** * array,
                        gint* length,
                        gint* size,
                        TubaPlace* value);
static void _vala_array_add52 (gchar** * array,
                        gint* length,
                        gint* size,
                        gchar* value);
static void ____lambda156__tuba_network_node_callback (JsonNode* node,
                                                gpointer self,
                                                GError** error);
static void _vala_array_add53 (gchar** * array,
                        gint* length,
                        gint* size,
                        gchar* value);
VALA_EXTERN void tuba_settings_set_favorite_lists_ids (TubaSettings* self,
                                           gchar** value,
                                           gint value_length1);
VALA_EXTERN void tuba_views_base_set_is_sidebar_item (TubaViewsBase* self,
                                          gboolean value);
VALA_EXTERN void tuba_views_base_set_show_back_button (TubaViewsBase* self,
                                           gboolean value);
static void tuba_instance_account_init_notifications_data_free (gpointer _data);
VALA_EXTERN void tuba_instance_account_init_notifications (TubaInstanceAccount* self,
                                               GAsyncReadyCallback _callback_,
                                               gpointer _user_data_);
VALA_EXTERN void tuba_instance_account_init_notifications_finish (TubaInstanceAccount* self,
                                                      GAsyncResult* _res_);
static gboolean tuba_instance_account_init_notifications_co (TubaInstanceAccountInitNotificationsData* _data_);
VALA_EXTERN gchar* tuba_views_notifications_get_notifications_excluded_types_query_param (void);
VALA_EXTERN void tuba_request_v2_add_parameter (TubaRequestV2* self,
                                    const gchar* key,
                                    const gchar* value);
VALA_EXTERN gint tuba_instance_account_get_last_read_id (TubaInstanceAccount* self);
static void tuba_instance_account_init_notifications_ready (GObject* source_object,
                                                     GAsyncResult* _res_,
                                                     gpointer _user_data_);
VALA_EXTERN JsonArray* tuba_network_get_array_mstd (JsonParser* parser);
VALA_EXTERN void tuba_instance_account_set_unread_count (TubaInstanceAccount* self,
                                             gint value);
VALA_EXTERN gint tuba_instance_account_get_unread_count (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_last_received_id (TubaInstanceAccount* self,
                                                 gint value);
static void tuba_instance_account_real_check_notifications_data_free (gpointer _data);
static void tuba_instance_account_real_check_notifications (TubaInstanceAccount* self,
                                                     GAsyncReadyCallback _callback_,
                                                     gpointer _user_data_);
static gboolean tuba_instance_account_real_check_notifications_co (TubaInstanceAccountCheckNotificationsData* _data_);
static void tuba_instance_account_check_notifications_ready (GObject* source_object,
                                                      GAsyncResult* _res_,
                                                      gpointer _user_data_);
VALA_EXTERN JsonObject* tuba_network_parse (TubaNetwork* self,
                                JsonParser* parser);
VALA_EXTERN void tuba_instance_account_set_last_read_id (TubaInstanceAccount* self,
                                             gint value);
static void tuba_instance_account_check_announcements_data_free (gpointer _data);
static gboolean tuba_instance_account_check_announcements_co (TubaInstanceAccountCheckAnnouncementsData* _data_);
static void tuba_instance_account_check_announcements_ready (GObject* source_object,
                                                      GAsyncResult* _res_,
                                                      gpointer _user_data_);
static Block50Data* block50_data_ref (Block50Data* _data50_);
static void block50_data_unref (void * _userdata_);
static void ____lambda174_ (Block50Data* _data50_,
                     JsonArray* array,
                     guint i,
                     JsonNode* node);
static void _____lambda174__json_array_foreach (JsonArray* array,
                                         guint index_,
                                         JsonNode* element_node,
                                         gpointer self);
VALA_EXTERN void tuba_instance_account_set_unread_announcements (TubaInstanceAccount* self,
                                                     gint value);
static void tuba_instance_account_read_notifications_data_free (gpointer _data);
VALA_EXTERN void tuba_instance_account_read_notifications (TubaInstanceAccount* self,
                                               gint up_to_id,
                                               GAsyncReadyCallback _callback_,
                                               gpointer _user_data_);
VALA_EXTERN void tuba_instance_account_read_notifications_finish (TubaInstanceAccount* self,
                                                      GAsyncResult* _res_);
static gboolean tuba_instance_account_read_notifications_co (TubaInstanceAccountReadNotificationsData* _data_);
VALA_EXTERN void tuba_request_v2_add_form_data (TubaRequestV2* self,
                                    const gchar* name,
                                    const gchar* val);
static void tuba_instance_account_read_notifications_ready (GObject* source_object,
                                                     GAsyncResult* _res_,
                                                     gpointer _user_data_);
VALA_EXTERN void tuba_instance_account_send_toast (TubaInstanceAccount* self,
                                       TubaAPINotification* obj);
static Block51Data* block51_data_ref (Block51Data* _data51_);
static void block51_data_unref (void * _userdata_);
VALA_EXTERN const gchar* tuba_api_notification_get_kind (TubaAPINotification* self);
VALA_EXTERN gchar** tuba_settings_get_muted_notification_types (TubaSettings* self,
                                                    gint* result_length1);
VALA_EXTERN gboolean tuba_settings_get_group_push_notifications (TubaSettings* self);
VALA_EXTERN GType tuba_api_status_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIStatus, g_object_unref)
VALA_EXTERN TubaAPIStatus* tuba_api_notification_get_status (TubaAPINotification* self);
VALA_EXTERN const gchar* tuba_api_status_get_id (TubaAPIStatus* self);
VALA_EXTERN const gchar* tuba_api_notification_get_id (TubaAPINotification* self);
VALA_EXTERN void tuba_api_notification_to_toast (TubaAPINotification* self,
                                     TubaInstanceAccount* issuer,
                                     gint others,
                                     GAsyncReadyCallback _callback_,
                                     gpointer _user_data_);
VALA_EXTERN GNotification* tuba_api_notification_to_toast_finish (TubaAPINotification* self,
                                                      GAsyncResult* _res_);
static void __lambda202_ (Block51Data* _data51_,
                   GObject* _obj,
                   GAsyncResult* res);
static void ___lambda202__gasync_ready_callback (GObject* source_object,
                                          GAsyncResult* res,
                                          gpointer self);
static gchar* tuba_instance_account_real_get_stream_url (TubaInstanceAccount* self);
VALA_EXTERN const gchar* tuba_instance_account_get_access_token (TubaInstanceAccount* self);
VALA_EXTERN GType tuba_streamable_event_get_type (void) G_GNUC_CONST ;
VALA_EXTERN TubaStreamableEvent* tuba_streamable_event_dup (const TubaStreamableEvent* self);
VALA_EXTERN void tuba_streamable_event_free (TubaStreamableEvent* self);
VALA_EXTERN void tuba_streamable_event_copy (const TubaStreamableEvent* self,
                                 TubaStreamableEvent* dest);
VALA_EXTERN void tuba_streamable_event_destroy (TubaStreamableEvent* self);
G_DEFINE_AUTO_CLEANUP_CLEAR_FUNC (TubaStreamableEvent, tuba_streamable_event_destroy)
static void tuba_instance_account_on_notification_event (TubaInstanceAccount* self,
                                                  TubaStreamableEvent* ev);
VALA_EXTERN JsonNode* tuba_streamable_event_get_node (TubaStreamableEvent *self,
                                          GError** error);
static void tuba_instance_account_real_on_notification_received (TubaInstanceAccount* self,
                                                          TubaAPINotification* entity);
VALA_EXTERN TubaAPIStatus* tuba_api_status_get_formal (TubaAPIStatus* self);
VALA_EXTERN gboolean tuba_api_status_get_tuba_filter_hidden (TubaAPIStatus* self);
VALA_EXTERN gint tuba_instance_account_get_unreviewed_follow_requests (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_unreviewed_follow_requests (TubaInstanceAccount* self,
                                                           gint value);
VALA_EXTERN gint tuba_instance_account_get_last_received_id (TubaInstanceAccount* self);
static gchar** tuba_instance_account_account_settings_notification_filters (TubaInstanceAccount* self,
                                                                     gint* result_length1);
static void tuba_instance_account_real_open_status_url (TubaInstanceAccount* self,
                                                 const gchar* url);
static void tuba_instance_account_real_answer_follow_request (TubaInstanceAccount* self,
                                                       const gchar* issuer_id,
                                                       const gchar* fr_id,
                                                       gboolean accept);
static void tuba_instance_account_real_follow_back (TubaInstanceAccount* self,
                                             const gchar* issuer_id,
                                             const gchar* acc_id);
static void tuba_instance_account_real_reply_to_status_uri (TubaInstanceAccount* self,
                                                     const gchar* issuer_id,
                                                     const gchar* uri);
static void tuba_instance_account_real_remove_from_followers (TubaInstanceAccount* self,
                                                       const gchar* issuer_id,
                                                       const gchar* acc_id);
static GSettings* tuba_instance_account_account_settings (TubaInstanceAccount* self);
VALA_EXTERN const gchar* tuba_instance_account_get_uuid (TubaInstanceAccount* self);
VALA_EXTERN TubaSettingsAccount* tuba_settings_account_new (const gchar* id);
VALA_EXTERN TubaSettingsAccount* tuba_settings_account_construct (GType object_type,
                                                      const gchar* id);
VALA_EXTERN GType tuba_settings_account_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaSettingsAccount, g_object_unref)
VALA_EXTERN gchar** tuba_settings_get_notification_filters (TubaSettings* self,
                                                gint* result_length1);
static gchar** _vala_array_dup35 (gchar** self,
                           gssize length);
VALA_EXTERN gchar** tuba_settings_account_get_notification_filters (TubaSettingsAccount* self,
                                                        gint* result_length1);
static gchar** _vala_array_dup36 (gchar** self,
                           gssize length);
VALA_EXTERN TubaInstanceAccount* tuba_instance_account_new (void);
VALA_EXTERN TubaInstanceAccount* tuba_instance_account_construct (GType object_type);
VALA_EXTERN TubaAPIAccount* tuba_api_account_new (void);
VALA_EXTERN TubaAPIAccount* tuba_api_account_construct (GType object_type);
VALA_EXTERN gboolean tuba_instance_account_get_admin_mode (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_admin_mode (TubaInstanceAccount* self,
                                           gboolean value);
VALA_EXTERN void tuba_instance_account_set_backend (TubaInstanceAccount* self,
                                        const gchar* value);
VALA_EXTERN void tuba_instance_account_set_instance (TubaInstanceAccount* self,
                                         const gchar* value);
VALA_EXTERN const gchar* tuba_instance_account_get_client_id (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_client_id (TubaInstanceAccount* self,
                                          const gchar* value);
VALA_EXTERN const gchar* tuba_instance_account_get_client_secret (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_client_secret (TubaInstanceAccount* self,
                                              const gchar* value);
VALA_EXTERN void tuba_instance_account_set_access_token (TubaInstanceAccount* self,
                                             const gchar* value);
VALA_EXTERN gboolean tuba_instance_account_get_tuba_probably_has_notification_filters (TubaInstanceAccount* self);
VALA_EXTERN gboolean tuba_instance_account_get_tuba_revoked (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_tuba_revoked (TubaInstanceAccount* self,
                                             gboolean value);
VALA_EXTERN void tuba_instance_account_set_tuba_cred_updated (TubaInstanceAccount* self,
                                                  gboolean value);
VALA_EXTERN void tuba_instance_account_set_tuba_verified_credentials (TubaInstanceAccount* self,
                                                          gboolean value);
VALA_EXTERN gchar* tuba_instance_account_get_handle_short (TubaInstanceAccount* self);
VALA_EXTERN const gchar* tuba_api_account_get_username (TubaAPIAccount* self);
VALA_EXTERN gchar* tuba_api_account_get_full_handle (TubaAPIAccount* self);
VALA_EXTERN void tuba_instance_account_set_uuid (TubaInstanceAccount* self,
                                     const gchar* value);
VALA_EXTERN gint tuba_instance_account_get_unread_announcements (TubaInstanceAccount* self);
VALA_EXTERN gint tuba_instance_account_get_filtered_notifications_count (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_filtered_notifications_count (TubaInstanceAccount* self,
                                                             gint value);
static void tuba_instance_account_real_activated (TubaInstanceAccount* self);
static void tuba_instance_account_real_deactivated (TubaInstanceAccount* self);
static void tuba_instance_account_real_added (TubaInstanceAccount* self);
VALA_EXTERN void tuba_streamable_set_subscribed (TubaStreamable* self,
                                     gboolean value);
static void tuba_instance_account_real_removed (TubaInstanceAccount* self);
VALA_EXTERN TubaInstanceAccountVisibility* tuba_instance_account_visibility_new (void);
VALA_EXTERN TubaInstanceAccountVisibility* tuba_instance_account_visibility_construct (GType object_type);
VALA_EXTERN void tuba_instance_account_visibility_set_id (TubaInstanceAccountVisibility* self,
                                              const gchar* value);
VALA_EXTERN const gchar* tuba_instance_account_visibility_get_name (TubaInstanceAccountVisibility* self);
VALA_EXTERN void tuba_instance_account_visibility_set_name (TubaInstanceAccountVisibility* self,
                                                const gchar* value);
VALA_EXTERN const gchar* tuba_instance_account_visibility_get_icon_name (TubaInstanceAccountVisibility* self);
VALA_EXTERN void tuba_instance_account_visibility_set_icon_name (TubaInstanceAccountVisibility* self,
                                                     const gchar* value);
VALA_EXTERN const gchar* tuba_instance_account_visibility_get_description (TubaInstanceAccountVisibility* self);
VALA_EXTERN void tuba_instance_account_visibility_set_description (TubaInstanceAccountVisibility* self,
                                                       const gchar* value);
VALA_EXTERN const gchar* tuba_instance_account_visibility_get_small_icon_name (TubaInstanceAccountVisibility* self);
VALA_EXTERN void tuba_instance_account_visibility_set_small_icon_name (TubaInstanceAccountVisibility* self,
                                                           const gchar* value);
static void tuba_instance_account_visibility_finalize (GObject * obj);
static GType tuba_instance_account_visibility_get_type_once (void);
static void _vala_tuba_instance_account_visibility_get_property (GObject * object,
                                                          guint property_id,
                                                          GValue * value,
                                                          GParamSpec * pspec);
static void _vala_tuba_instance_account_visibility_set_property (GObject * object,
                                                          guint property_id,
                                                          const GValue * value,
                                                          GParamSpec * pspec);
static gboolean _tuba_instance_account_status_content_type_compare_lambda79_ (const gchar* a,
                                                                       const gchar* b);
VALA_EXTERN const gchar* tuba_instance_account_status_content_type_get_mime (TubaInstanceAccountStatusContentType* self);
static gboolean __tuba_instance_account_status_content_type_compare_lambda79__gequal_func (gconstpointer a,
                                                                                    gconstpointer b);
VALA_EXTERN void tuba_instance_account_status_content_type_set_mime (TubaInstanceAccountStatusContentType* self,
                                                         const gchar* value);
VALA_EXTERN void tuba_instance_account_status_content_type_set_icon_name (TubaInstanceAccountStatusContentType* self,
                                                              const gchar* value);
VALA_EXTERN void tuba_instance_account_status_content_type_set_title (TubaInstanceAccountStatusContentType* self,
                                                          const gchar* value);
VALA_EXTERN void tuba_instance_account_status_content_type_set_syntax (TubaInstanceAccountStatusContentType* self,
                                                           const gchar* value);
VALA_EXTERN const gchar* tuba_instance_account_status_content_type_get_icon_name (TubaInstanceAccountStatusContentType* self);
VALA_EXTERN const gchar* tuba_instance_account_status_content_type_get_title (TubaInstanceAccountStatusContentType* self);
VALA_EXTERN const gchar* tuba_instance_account_status_content_type_get_syntax (TubaInstanceAccountStatusContentType* self);
static void tuba_instance_account_status_content_type_finalize (GObject * obj);
static GType tuba_instance_account_status_content_type_get_type_once (void);
static void _vala_tuba_instance_account_status_content_type_get_property (GObject * object,
                                                                   guint property_id,
                                                                   GValue * value,
                                                                   GParamSpec * pspec);
static void _vala_tuba_instance_account_status_content_type_set_property (GObject * object,
                                                                   guint property_id,
                                                                   const GValue * value,
                                                                   GParamSpec * pspec);
static GObject * tuba_instance_account_constructor (GType type,
                                             guint n_construct_properties,
                                             GObjectConstructParam * construct_properties);
VALA_EXTERN void tuba_streamable_construct_streamable (TubaStreamable* self);
static void _tuba_instance_account_on_notification_event_tuba_streamable_stream_event (TubaStreamable* _sender,
                                                                                TubaStreamableEvent* ev,
                                                                                gpointer self);
static void _tuba_instance_account_on_network_change_g_object_notify (GObject* _sender,
                                                               GParamSpec* pspec,
                                                               gpointer self);
VALA_EXTERN gchar* tuba_streamable_get_stream_url (TubaStreamable* self);
VALA_EXTERN const gchar* tuba_streamable_get_t_connection_url (TubaStreamable* self);
VALA_EXTERN void tuba_streamable_set_t_connection_url (TubaStreamable* self,
                                           const gchar* value);
VALA_EXTERN gboolean tuba_streamable_get_subscribed (TubaStreamable* self);
static void tuba_instance_account_finalize (GObject * obj);
static GType tuba_instance_account_get_type_once (void);
static void _vala_tuba_instance_account_get_property (GObject * object,
                                               guint property_id,
                                               GValue * value,
                                               GParamSpec * pspec);
static void _vala_tuba_instance_account_set_property (GObject * object,
                                               guint property_id,
                                               const GValue * value,
                                               GParamSpec * pspec);
static void _vala_array_destroy (gpointer array,
                          gssize array_length,
                          GDestroyNotify destroy_func);
static void _vala_array_free (gpointer array,
                       gssize array_length,
                       GDestroyNotify destroy_func);

const gchar* TUBA_INSTANCE_ACCOUNT_ALL_HANDLED_NOTIFICATION_TYPES[21] = {TUBA_INSTANCE_ACCOUNT_KIND_MENTION, TUBA_INSTANCE_ACCOUNT_KIND_REBLOG, TUBA_INSTANCE_ACCOUNT_KIND_FAVOURITE, TUBA_INSTANCE_ACCOUNT_KIND_FOLLOW, TUBA_INSTANCE_ACCOUNT_KIND_POLL, TUBA_INSTANCE_ACCOUNT_KIND_FOLLOW_REQUEST, TUBA_INSTANCE_ACCOUNT_KIND_REMOTE_REBLOG, TUBA_INSTANCE_ACCOUNT_KIND_EDITED, TUBA_INSTANCE_ACCOUNT_KIND_REPLY, TUBA_INSTANCE_ACCOUNT_KIND_SEVERED_RELATIONSHIPS, TUBA_INSTANCE_ACCOUNT_KIND_ADMIN_REPORT, TUBA_INSTANCE_ACCOUNT_KIND_ADMIN_SIGNUP, TUBA_INSTANCE_ACCOUNT_KIND_STATUS, TUBA_INSTANCE_ACCOUNT_KIND_PLEROMA_REACTION, TUBA_INSTANCE_ACCOUNT_KIND_REACTION, TUBA_INSTANCE_ACCOUNT_KIND_ANNUAL_REPORT, TUBA_INSTANCE_ACCOUNT_KIND_MODERATION_WARNING, TUBA_INSTANCE_ACCOUNT_KIND_QUOTE, TUBA_INSTANCE_ACCOUNT_KIND_QUOTE_UPDATE, TUBA_INSTANCE_ACCOUNT_KIND_COLLECTION_ADDED, TUBA_INSTANCE_ACCOUNT_KIND_COLLECTION_EDITED};
static const gchar* TUBA_INSTANCE_ACCOUNT_GROUPED_KINDS[2] = {TUBA_INSTANCE_ACCOUNT_KIND_FAVOURITE, TUBA_INSTANCE_ACCOUNT_KIND_REBLOG};

static inline gpointer
tuba_instance_account_get_instance_private (TubaInstanceAccount* self)
{
	return G_STRUCT_MEMBER_P (self, TubaInstanceAccount_private_offset);
}

 G_GNUC_NO_INLINE static GType
tuba_instance_account_instance_features_get_type_once (void)
{
	static const GFlagsValue values[] = {{TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_NONE, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_NONE", "none"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_QUOTE, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_QUOTE", "quote"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_EMOJI_REACTIONS, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_EMOJI_REACTIONS", "emoji-reactions"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_BUBBLE, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_BUBBLE", "bubble"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GROUP_NOTIFICATIONS, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GROUP_NOTIFICATIONS", "group-notifications"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_FEATURE_TAGS, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_FEATURE_TAGS", "feature-tags"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ENDORSE_USERS, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ENDORSE_USERS", "endorse-users"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_MUTUALS, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_MUTUALS", "mutuals"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_TRANSLATION, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_TRANSLATION", "translation"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ICESHRIMP, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ICESHRIMP", "iceshrimp"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GLITCH, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GLITCH", "glitch"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY", "local-only"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GOTOSOCIAL, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GOTOSOCIAL", "gotosocial"}, {0, NULL, NULL}};
	GType tuba_instance_account_instance_features_type_id;
	tuba_instance_account_instance_features_type_id = g_flags_register_static ("TubaInstanceAccountInstanceFeatures", values);
	return tuba_instance_account_instance_features_type_id;
}

GType
tuba_instance_account_instance_features_get_type (void)
{
	static GType tuba_instance_account_instance_features_type_id__once = 0;
	if (g_once_init_enter_pointer (&tuba_instance_account_instance_features_type_id__once)) {
		GType tuba_instance_account_instance_features_type_id;
		tuba_instance_account_instance_features_type_id = tuba_instance_account_instance_features_get_type_once ();
		g_once_init_leave_pointer (&tuba_instance_account_instance_features_type_id__once, tuba_instance_account_instance_features_type_id);
	}
	return tuba_instance_account_instance_features_type_id__once;
}

static const gchar*
string_to_string (const gchar* self)
{
	const gchar* result;
	g_return_val_if_fail (self != NULL, NULL);
	result = self;
	return result;
}

static void
tuba_instance_account_tuba_instance_features_update_and_save (TubaInstanceAccount* self,
                                                              TubaInstanceAccountInstanceFeatures features)
{
	gboolean _tmp0_ = FALSE;
	TubaInstanceAccountInstanceFeatures _tmp1_;
	GError* _inner_error0_ = NULL;
	g_return_if_fail (self != NULL);
	_tmp1_ = self->priv->_tuba_instance_features;
	if (features == _tmp1_) {
		_tmp0_ = TRUE;
	} else {
		TubaSettings* _tmp2_;
		_tmp2_ = tuba_settings;
		_tmp0_ = !g_settings_get_boolean ((GSettings*) _tmp2_, "auto-detect-features");
	}
	if (_tmp0_) {
		return;
	}
	tuba_instance_account_set_tuba_instance_features (self, features);
	{
		TubaAccountStore* _tmp3_;
		_tmp3_ = tuba_accounts;
		tuba_account_store_update_account (_tmp3_, self, &_inner_error0_);
		if (G_UNLIKELY (_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
	}
	goto __finally0;
	__catch0_g_error:
	{
		GError* e = NULL;
		const gchar* _tmp4_;
		const gchar* _tmp5_;
		const gchar* _tmp6_;
		GError* _tmp7_;
		gchar* _tmp8_;
		gchar* _tmp9_;
		GError* _tmp10_;
		const gchar* _tmp11_;
		const gchar* _tmp12_;
		gchar* _tmp13_;
		gchar* _tmp14_;
		e = _inner_error0_;
		_inner_error0_ = NULL;
		_tmp4_ = tuba_api_account_get_id ((TubaAPIAccount*) self);
		_tmp5_ = _tmp4_;
		_tmp6_ = string_to_string (_tmp5_);
		_tmp7_ = e;
		_tmp8_ = g_strdup_printf ("%i", _tmp7_->code);
		_tmp9_ = _tmp8_;
		_tmp10_ = e;
		_tmp11_ = _tmp10_->message;
		_tmp12_ = string_to_string (_tmp11_);
		_tmp13_ = g_strconcat ("Couldn't update instance features for ", _tmp6_, ": ", _tmp9_, " ", _tmp12_, NULL);
		_tmp14_ = _tmp13_;
		g_critical ("InstanceAccount.vala:94: %s", _tmp14_);
		_g_free0 (_tmp14_);
		_g_free0 (_tmp9_);
		_g_error_free0 (e);
	}
	__finally0:
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error0_->message, g_quark_to_string (_inner_error0_->domain), _inner_error0_->code);
		g_clear_error (&_inner_error0_);
		return;
	}
}

void
tuba_instance_account_tuba_update_iceshrimp_api_key (TubaInstanceAccount* self,
                                                     const gchar* new_key)
{
	const gchar* _tmp0_;
	GError* _inner_error0_ = NULL;
	g_return_if_fail (self != NULL);
	_tmp0_ = self->priv->_tuba_iceshrimp_api_key;
	if (g_strcmp0 (_tmp0_, new_key) == 0) {
		return;
	}
	tuba_instance_account_set_tuba_iceshrimp_api_key (self, new_key);
	{
		TubaAccountStore* _tmp1_;
		_tmp1_ = tuba_accounts;
		tuba_account_store_update_account (_tmp1_, self, &_inner_error0_);
		if (G_UNLIKELY (_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
	}
	goto __finally0;
	__catch0_g_error:
	{
		GError* e = NULL;
		const gchar* _tmp2_;
		const gchar* _tmp3_;
		const gchar* _tmp4_;
		GError* _tmp5_;
		gchar* _tmp6_;
		gchar* _tmp7_;
		GError* _tmp8_;
		const gchar* _tmp9_;
		const gchar* _tmp10_;
		gchar* _tmp11_;
		gchar* _tmp12_;
		e = _inner_error0_;
		_inner_error0_ = NULL;
		_tmp2_ = tuba_api_account_get_id ((TubaAPIAccount*) self);
		_tmp3_ = _tmp2_;
		_tmp4_ = string_to_string (_tmp3_);
		_tmp5_ = e;
		_tmp6_ = g_strdup_printf ("%i", _tmp5_->code);
		_tmp7_ = _tmp6_;
		_tmp8_ = e;
		_tmp9_ = _tmp8_->message;
		_tmp10_ = string_to_string (_tmp9_);
		_tmp11_ = g_strconcat ("Couldn't update instance features for ", _tmp4_, ": ", _tmp7_, " ", _tmp10_, NULL);
		_tmp12_ = _tmp11_;
		g_critical ("InstanceAccount.vala:105: %s", _tmp12_);
		_g_free0 (_tmp12_);
		_g_free0 (_tmp7_);
		_g_error_free0 (e);
	}
	__finally0:
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error0_->message, g_quark_to_string (_inner_error0_->domain), _inner_error0_->code);
		g_clear_error (&_inner_error0_);
		return;
	}
}

static void
tuba_instance_account_tuba_update_streaming_url (TubaInstanceAccount* self,
                                                 const gchar* new_url)
{
	gchar* new_host = NULL;
	const gchar* _tmp0_;
	gchar* _tmp1_;
	const gchar* _tmp21_;
	const gchar* _tmp22_;
	const gchar* _tmp23_;
	GError* _inner_error0_ = NULL;
	g_return_if_fail (self != NULL);
	g_return_if_fail (new_url != NULL);
	if (g_strcmp0 (new_url, "") == 0) {
		return;
	}
	_tmp0_ = self->priv->_instance;
	_tmp1_ = g_strdup (_tmp0_);
	new_host = _tmp1_;
	{
		GUri* new_uri = NULL;
		GUri* _tmp2_;
		gchar* new_host_uri = NULL;
		GUri* _tmp3_;
		const gchar* _tmp4_;
		gchar* _tmp5_;
		gboolean _tmp6_ = FALSE;
		const gchar* _tmp7_;
		_tmp2_ = g_uri_parse (new_url, G_URI_FLAGS_NONE, &_inner_error0_);
		new_uri = _tmp2_;
		if (G_UNLIKELY (_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
		_tmp3_ = new_uri;
		_tmp4_ = g_uri_get_host (_tmp3_);
		_tmp5_ = g_strdup (_tmp4_);
		new_host_uri = _tmp5_;
		_tmp7_ = new_host_uri;
		if (_tmp7_ != NULL) {
			const gchar* _tmp8_;
			_tmp8_ = new_host_uri;
			_tmp6_ = g_strcmp0 (_tmp8_, "") != 0;
		} else {
			_tmp6_ = FALSE;
		}
		if (_tmp6_) {
			const gchar* _tmp9_;
			const gchar* _tmp10_;
			gchar* _tmp11_;
			_tmp9_ = new_host_uri;
			_tmp10_ = string_to_string (_tmp9_);
			_tmp11_ = g_strconcat ("https://", _tmp10_, NULL);
			_g_free0 (new_host);
			new_host = _tmp11_;
		}
		_g_free0 (new_host_uri);
		_g_uri_unref0 (new_uri);
	}
	goto __finally0;
	__catch0_g_error:
	{
		GError* e = NULL;
		const gchar* _tmp12_;
		GError* _tmp13_;
		gchar* _tmp14_;
		gchar* _tmp15_;
		GError* _tmp16_;
		const gchar* _tmp17_;
		const gchar* _tmp18_;
		gchar* _tmp19_;
		gchar* _tmp20_;
		e = _inner_error0_;
		_inner_error0_ = NULL;
		_tmp12_ = string_to_string (new_url);
		_tmp13_ = e;
		_tmp14_ = g_strdup_printf ("%i", _tmp13_->code);
		_tmp15_ = _tmp14_;
		_tmp16_ = e;
		_tmp17_ = _tmp16_->message;
		_tmp18_ = string_to_string (_tmp17_);
		_tmp19_ = g_strconcat (_tmp12_, " is not a valid URI: ", _tmp15_, " ", _tmp18_, NULL);
		_tmp20_ = _tmp19_;
		g_warning ("InstanceAccount.vala:120: %s", _tmp20_);
		_g_free0 (_tmp20_);
		_g_free0 (_tmp15_);
		_g_error_free0 (e);
	}
	__finally0:
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		_g_free0 (new_host);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error0_->message, g_quark_to_string (_inner_error0_->domain), _inner_error0_->code);
		g_clear_error (&_inner_error0_);
		return;
	}
	_tmp21_ = new_host;
	_tmp22_ = tuba_instance_account_get_tuba_streaming_url (self);
	_tmp23_ = _tmp22_;
	if (g_strcmp0 (_tmp21_, _tmp23_) != 0) {
		const gchar* _tmp24_;
		_tmp24_ = new_host;
		tuba_instance_account_set_tuba_streaming_url (self, _tmp24_);
		{
			TubaAccountStore* _tmp25_;
			TubaApplication* _tmp26_;
			TubaStreams* _tmp27_;
			TubaStreams* _tmp28_;
			const gchar* _tmp29_;
			const gchar* _tmp30_;
			_tmp25_ = tuba_accounts;
			tuba_account_store_update_account (_tmp25_, self, &_inner_error0_);
			if (G_UNLIKELY (_inner_error0_ != NULL)) {
				goto __catch1_g_error;
			}
			_tmp26_ = tuba_app;
			_tmp27_ = tuba_application_get_app_streams (_tmp26_);
			_tmp28_ = _tmp27_;
			_tmp29_ = self->priv->_instance;
			_tmp30_ = new_host;
			tuba_streams_upgrade (_tmp28_, _tmp29_, _tmp30_);
		}
		goto __finally1;
		__catch1_g_error:
		{
			GError* e = NULL;
			const gchar* _tmp31_;
			const gchar* _tmp32_;
			const gchar* _tmp33_;
			GError* _tmp34_;
			gchar* _tmp35_;
			gchar* _tmp36_;
			GError* _tmp37_;
			const gchar* _tmp38_;
			const gchar* _tmp39_;
			gchar* _tmp40_;
			gchar* _tmp41_;
			e = _inner_error0_;
			_inner_error0_ = NULL;
			_tmp31_ = tuba_api_account_get_id ((TubaAPIAccount*) self);
			_tmp32_ = _tmp31_;
			_tmp33_ = string_to_string (_tmp32_);
			_tmp34_ = e;
			_tmp35_ = g_strdup_printf ("%i", _tmp34_->code);
			_tmp36_ = _tmp35_;
			_tmp37_ = e;
			_tmp38_ = _tmp37_->message;
			_tmp39_ = string_to_string (_tmp38_);
			_tmp40_ = g_strconcat ("Couldn't update instance features for ", _tmp33_, ": ", _tmp36_, " ", _tmp39_, NULL);
			_tmp41_ = _tmp40_;
			g_critical ("InstanceAccount.vala:129: %s", _tmp41_);
			_g_free0 (_tmp41_);
			_g_free0 (_tmp36_);
			_g_error_free0 (e);
		}
		__finally1:
		if (G_UNLIKELY (_inner_error0_ != NULL)) {
			_g_free0 (new_host);
			g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error0_->message, g_quark_to_string (_inner_error0_->domain), _inner_error0_->code);
			g_clear_error (&_inner_error0_);
			return;
		}
	}
	_g_free0 (new_host);
}

static gboolean
_tuba_instance_account_gather_fav_tags_gsource_func (gpointer self)
{
	gboolean result;
	result = tuba_instance_account_gather_fav_tags ((TubaInstanceAccount*) self);
	return result;
}

void
tuba_instance_account_reconnect (TubaInstanceAccount* self)
{
	g_return_if_fail (self != NULL);
	tuba_instance_account_gather_instance_info (self, NULL, NULL);
	tuba_instance_account_gather_instance_custom_emojis (self, NULL, NULL);
	tuba_instance_account_gather_fav_lists (self, NULL, NULL);
	g_idle_add_full (G_PRIORITY_DEFAULT_IDLE, _tuba_instance_account_gather_fav_tags_gsource_func, g_object_ref (self), g_object_unref);
	tuba_instance_account_check_announcements (self, NULL, NULL);
	tuba_instance_account_check_notifications (self, NULL, NULL);
}

static void
tuba_instance_account_on_network_change (TubaInstanceAccount* self)
{
	gboolean _tmp0_ = FALSE;
	gboolean _tmp1_;
	gboolean _tmp2_;
	g_return_if_fail (self != NULL);
	_tmp1_ = tuba_instance_account_get_is_active (self);
	_tmp2_ = _tmp1_;
	if (_tmp2_) {
		TubaApplication* _tmp3_;
		gboolean _tmp4_;
		gboolean _tmp5_;
		_tmp3_ = tuba_app;
		_tmp4_ = tuba_application_get_is_online (_tmp3_);
		_tmp5_ = _tmp4_;
		_tmp0_ = _tmp5_;
	} else {
		_tmp0_ = FALSE;
	}
	if (_tmp0_) {
		gboolean _tmp6_ = FALSE;
		TubaAccountStore* _tmp7_;
		TubaInstanceAccount* _tmp8_;
		TubaInstanceAccount* _tmp9_;
		gboolean _tmp12_;
		_tmp7_ = tuba_accounts;
		_tmp8_ = tuba_account_store_get_active (_tmp7_);
		_tmp9_ = _tmp8_;
		if (_tmp9_ == self) {
			gboolean _tmp10_;
			_tmp10_ = self->priv->_tuba_verified_credentials;
			_tmp6_ = !_tmp10_;
		} else {
			_tmp6_ = FALSE;
		}
		if (_tmp6_) {
			TubaAccountStore* _tmp11_;
			_tmp11_ = tuba_accounts;
			tuba_account_store_verify_credentials (_tmp11_, self, NULL, NULL);
		}
		_tmp12_ = self->priv->_tuba_cred_updated;
		if (!_tmp12_) {
			TubaAccountStore* _tmp13_;
			_tmp13_ = tuba_accounts;
			tuba_account_store_update_account_info (_tmp13_, self, NULL, NULL);
		} else {
			gboolean _tmp14_;
			_tmp14_ = self->priv->_needs_update;
			if (_tmp14_) {
				tuba_instance_account_set_needs_update (self, FALSE);
				tuba_instance_account_on_network_change_real (self, NULL, NULL);
			}
		}
		tuba_instance_account_reconnect (self);
	}
}

static void
tuba_instance_account_on_network_change_real_data_free (gpointer _data)
{
	TubaInstanceAccountOnNetworkChangeRealData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->self);
	g_slice_free (TubaInstanceAccountOnNetworkChangeRealData, _data_);
}

static gpointer
_g_object_ref0 (gpointer self)
{
	return self ? g_object_ref (self) : NULL;
}

static void
tuba_instance_account_on_network_change_real (TubaInstanceAccount* self,
                                              GAsyncReadyCallback _callback_,
                                              gpointer _user_data_)
{
	TubaInstanceAccountOnNetworkChangeRealData* _data_;
	TubaInstanceAccount* _tmp0_;
	g_return_if_fail (self != NULL);
	_data_ = g_slice_new0 (TubaInstanceAccountOnNetworkChangeRealData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, tuba_instance_account_on_network_change_real_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	tuba_instance_account_on_network_change_real_co (_data_);
}

static void
tuba_instance_account_on_network_change_real_finish (TubaInstanceAccount* self,
                                                     GAsyncResult* _res_)
{
	TubaInstanceAccountOnNetworkChangeRealData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), NULL);
}

static void
tuba_instance_account_on_network_change_real_ready (GObject* source_object,
                                                    GAsyncResult* _res_,
                                                    gpointer _user_data_)
{
	TubaInstanceAccountOnNetworkChangeRealData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	tuba_instance_account_on_network_change_real_co (_data_);
}

static void
_vala_JsonNode_free (JsonNode* self)
{
	g_boxed_free (json_node_get_type (), self);
}

static gboolean
tuba_instance_account_on_network_change_real_co (TubaInstanceAccountOnNetworkChangeRealData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = tuba_api_account_get_id ((TubaAPIAccount*) _data_->self);
	_data_->_tmp1_ = _data_->_tmp0_;
	_data_->_tmp2_ = string_to_string (_data_->_tmp1_);
	_data_->_tmp3_ = g_strconcat ("/api/v1/accounts/", _data_->_tmp2_, NULL);
	_data_->_tmp4_ = _data_->_tmp3_;
	_data_->_tmp5_ = tuba_accounts;
	_data_->_tmp6_ = tuba_account_store_get_active (_data_->_tmp5_);
	_data_->_tmp7_ = _data_->_tmp6_;
	_data_->_tmp8_ = _g_object_ref0 (_data_->_tmp7_);
	_data_->_tmp9_ = NULL;
	_data_->_tmp9_ = tuba_request_v2_new (_data_->_tmp4_, TUBA_REQUEST_V2_METHOD_GET);
	tuba_request_v2_set_account (_data_->_tmp9_, _data_->_tmp8_);
	_g_object_unref0 (_data_->_tmp8_);
	_data_->_tmp10_ = _data_->_tmp9_;
	_g_free0 (_data_->_tmp4_);
	_data_->req = _data_->_tmp10_;
	{
		_data_->_tmp11_ = _data_->req;
		_data_->_state_ = 1;
		tuba_request_v2_exec (_data_->_tmp11_, tuba_instance_account_on_network_change_real_ready, _data_);
		return FALSE;
		_state_1:
		_data_->_tmp12_ = tuba_request_v2_exec_finish (_data_->_tmp11_, _data_->_res_, NULL, &_data_->_inner_error0_);
		_data_->in_stream = _data_->_tmp12_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
		_data_->_tmp13_ = _data_->in_stream;
		_data_->_state_ = 2;
		tuba_network_get_parser_from_inputstream_async (_data_->_tmp13_, NULL, tuba_instance_account_on_network_change_real_ready, _data_);
		return FALSE;
		_state_2:
		_data_->_tmp14_ = tuba_network_get_parser_from_inputstream_finish (_data_->_res_, &_data_->_inner_error0_);
		_data_->parser = _data_->_tmp14_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			_g_object_unref0 (_data_->in_stream);
			goto __catch0_g_error;
		}
		_data_->_tmp15_ = tuba_network;
		_data_->_tmp16_ = _data_->parser;
		_data_->_tmp17_ = tuba_network_parse_node (_data_->_tmp15_, _data_->_tmp16_);
		_data_->node = _data_->_tmp17_;
		_data_->_tmp18_ = _data_->node;
		if (_data_->_tmp18_ == NULL) {
			tuba_instance_account_set_needs_update (_data_->self, TRUE);
			__vala_JsonNode_free0 (_data_->node);
			_g_object_unref0 (_data_->parser);
			_g_object_unref0 (_data_->in_stream);
			_g_object_unref0 (_data_->req);
			g_task_return_pointer (_data_->_async_result, _data_, NULL);
			if (_data_->_state_ != 0) {
				while (!g_task_get_completed (_data_->_async_result)) {
					g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
				}
			}
			g_object_unref (_data_->_async_result);
			return FALSE;
		}
		_data_->_tmp19_ = _data_->node;
		_data_->_tmp20_ = tuba_api_account_from (_data_->_tmp19_, &_data_->_inner_error0_);
		_data_->acc = _data_->_tmp20_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			__vala_JsonNode_free0 (_data_->node);
			_g_object_unref0 (_data_->parser);
			_g_object_unref0 (_data_->in_stream);
			goto __catch0_g_error;
		}
		_data_->_tmp22_ = tuba_api_account_get_display_name ((TubaAPIAccount*) _data_->self);
		_data_->_tmp23_ = _data_->_tmp22_;
		_data_->_tmp24_ = _data_->acc;
		_data_->_tmp25_ = tuba_api_account_get_display_name (_data_->_tmp24_);
		_data_->_tmp26_ = _data_->_tmp25_;
		if (g_strcmp0 (_data_->_tmp23_, _data_->_tmp26_) != 0) {
			_data_->_tmp21_ = TRUE;
		} else {
			_data_->_tmp27_ = tuba_api_account_get_avatar ((TubaAPIAccount*) _data_->self);
			_data_->_tmp28_ = _data_->_tmp27_;
			_data_->_tmp29_ = _data_->acc;
			_data_->_tmp30_ = tuba_api_account_get_avatar (_data_->_tmp29_);
			_data_->_tmp31_ = _data_->_tmp30_;
			_data_->_tmp21_ = g_strcmp0 (_data_->_tmp28_, _data_->_tmp31_) != 0;
		}
		if (_data_->_tmp21_) {
			_data_->_tmp32_ = _data_->acc;
			_data_->_tmp33_ = tuba_api_account_get_display_name (_data_->_tmp32_);
			_data_->_tmp34_ = _data_->_tmp33_;
			tuba_api_account_set_display_name ((TubaAPIAccount*) _data_->self, _data_->_tmp34_);
			_data_->_tmp35_ = _data_->acc;
			_data_->_tmp36_ = tuba_api_account_get_avatar (_data_->_tmp35_);
			_data_->_tmp37_ = _data_->_tmp36_;
			tuba_api_account_set_avatar ((TubaAPIAccount*) _data_->self, _data_->_tmp37_);
		}
		_g_object_unref0 (_data_->acc);
		__vala_JsonNode_free0 (_data_->node);
		_g_object_unref0 (_data_->parser);
		_g_object_unref0 (_data_->in_stream);
	}
	goto __finally0;
	__catch0_g_error:
	{
		_data_->e = _data_->_inner_error0_;
		_data_->_inner_error0_ = NULL;
		_data_->_tmp38_ = tuba_api_account_get_id ((TubaAPIAccount*) _data_->self);
		_data_->_tmp39_ = _data_->_tmp38_;
		_data_->_tmp40_ = string_to_string (_data_->_tmp39_);
		_data_->_tmp41_ = _data_->e;
		_data_->_tmp42_ = g_strdup_printf ("%i", _data_->_tmp41_->code);
		_data_->_tmp43_ = _data_->_tmp42_;
		_data_->_tmp44_ = _data_->e;
		_data_->_tmp45_ = _data_->_tmp44_->message;
		_data_->_tmp46_ = string_to_string (_data_->_tmp45_);
		_data_->_tmp47_ = g_strconcat ("Couldn't update account ", _data_->_tmp40_, ": ", _data_->_tmp43_, " ", _data_->_tmp46_, NULL);
		_data_->_tmp48_ = _data_->_tmp47_;
		g_warning ("InstanceAccount.vala:297: %s", _data_->_tmp48_);
		_g_free0 (_data_->_tmp48_);
		_g_free0 (_data_->_tmp43_);
		_g_error_free0 (_data_->e);
	}
	__finally0:
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		_g_object_unref0 (_data_->req);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error0_->message, g_quark_to_string (_data_->_inner_error0_->domain), _data_->_inner_error0_->code);
		g_clear_error (&_data_->_inner_error0_);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_g_object_unref0 (_data_->req);
	g_task_return_pointer (_data_->_async_result, _data_, NULL);
	if (_data_->_state_ != 0) {
		while (!g_task_get_completed (_data_->_async_result)) {
			g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
		}
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}

TubaInstanceAccount*
tuba_instance_account_construct_empty (GType object_type,
                                       const gchar* instance)
{
	TubaInstanceAccount * self = NULL;
	g_return_val_if_fail (instance != NULL, NULL);
	self = (TubaInstanceAccount*) g_object_new (object_type, "id", "", "instance", instance, NULL);
	return self;
}

TubaInstanceAccount*
tuba_instance_account_new_empty (const gchar* instance)
{
	return tuba_instance_account_construct_empty (TUBA_TYPE_INSTANCE_ACCOUNT, instance);
}

void
tuba_instance_account_set_visibility (TubaInstanceAccount* self,
                                      TubaInstanceAccountVisibility* obj)
{
	GeeHashMap* _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	GListStore* _tmp3_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (obj != NULL);
	_tmp0_ = self->visibility;
	_tmp1_ = tuba_instance_account_visibility_get_id (obj);
	_tmp2_ = _tmp1_;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp0_, _tmp2_, obj);
	_tmp3_ = self->visibility_list;
	g_list_store_append (_tmp3_, (GObject*) obj);
}

gpointer
tuba_instance_account_create_entity (TubaInstanceAccount* self,
                                     GType t_type,
                                     GBoxedCopyFunc t_dup_func,
                                     GDestroyNotify t_destroy_func,
                                     JsonNode* node,
                                     GError** error)
{
	GType type = G_TYPE_NONE;
	GeeHashMap* _tmp0_;
	TubaEntity* _tmp3_ = NULL;
	TubaEntity* _tmp4_;
	TubaEntity* _tmp5_;
	GError* _inner_error0_ = NULL;
	gpointer result;
	g_return_val_if_fail (self != NULL, NULL);
	g_return_val_if_fail (node != NULL, NULL);
	type = t_type;
	_tmp0_ = self->type_overrides;
	if (gee_abstract_map_has_key ((GeeAbstractMap*) _tmp0_, (gpointer) ((gintptr) type))) {
		GeeHashMap* _tmp1_;
		gpointer _tmp2_;
		_tmp1_ = self->type_overrides;
		_tmp2_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp1_, (gpointer) ((gintptr) type));
		type = (GType) ((gintptr) _tmp2_);
	}
	_tmp4_ = tuba_entity_from_json (type, node, &_inner_error0_);
	_tmp3_ = _tmp4_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return NULL;
	}
	_tmp5_ = _tmp3_;
	_tmp3_ = NULL;
	result = _tmp5_;
	_g_object_unref0 (_tmp3_);
	return result;
}

TubaEntity*
tuba_instance_account_create_dynamic_entity (TubaInstanceAccount* self,
                                             GType type,
                                             JsonNode* node,
                                             GError** error)
{
	GeeHashMap* _tmp0_;
	TubaEntity* _tmp3_ = NULL;
	TubaEntity* _tmp4_;
	TubaEntity* _tmp5_;
	GError* _inner_error0_ = NULL;
	TubaEntity* result;
	g_return_val_if_fail (self != NULL, NULL);
	g_return_val_if_fail (node != NULL, NULL);
	_tmp0_ = self->type_overrides;
	if (gee_abstract_map_has_key ((GeeAbstractMap*) _tmp0_, (gpointer) ((gintptr) type))) {
		GeeHashMap* _tmp1_;
		gpointer _tmp2_;
		_tmp1_ = self->type_overrides;
		_tmp2_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp1_, (gpointer) ((gintptr) type));
		type = (GType) ((gintptr) _tmp2_);
	}
	_tmp4_ = tuba_entity_from_json (type, node, &_inner_error0_);
	_tmp3_ = _tmp4_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return NULL;
	}
	_tmp5_ = _tmp3_;
	_tmp3_ = NULL;
	result = _tmp5_;
	_g_object_unref0 (_tmp3_);
	return result;
}

static void
tuba_instance_account_verify_credentials_data_free (gpointer _data)
{
	TubaInstanceAccountVerifyCredentialsData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->self);
	g_slice_free (TubaInstanceAccountVerifyCredentialsData, _data_);
}

void
tuba_instance_account_verify_credentials (TubaInstanceAccount* self,
                                          GAsyncReadyCallback _callback_,
                                          gpointer _user_data_)
{
	TubaInstanceAccountVerifyCredentialsData* _data_;
	TubaInstanceAccount* _tmp0_;
	g_return_if_fail (self != NULL);
	_data_ = g_slice_new0 (TubaInstanceAccountVerifyCredentialsData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, tuba_instance_account_verify_credentials_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	tuba_instance_account_verify_credentials_co (_data_);
}

void
tuba_instance_account_verify_credentials_finish (TubaInstanceAccount* self,
                                                 GAsyncResult* _res_,
                                                 GError** error)
{
	TubaInstanceAccountVerifyCredentialsData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), error);
	if (NULL == _data_) {
		return;
	}
}

static void
tuba_instance_account_verify_credentials_ready (GObject* source_object,
                                                GAsyncResult* _res_,
                                                gpointer _user_data_)
{
	TubaInstanceAccountVerifyCredentialsData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	tuba_instance_account_verify_credentials_co (_data_);
}

static gboolean
tuba_instance_account_verify_credentials_co (TubaInstanceAccountVerifyCredentialsData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = _g_object_ref0 (_data_->self);
	_data_->_tmp1_ = NULL;
	_data_->_tmp1_ = tuba_request_v2_new ("/api/v1/accounts/verify_credentials", TUBA_REQUEST_V2_METHOD_GET);
	tuba_request_v2_set_account (_data_->_tmp1_, _data_->_tmp0_);
	_g_object_unref0 (_data_->_tmp0_);
	_data_->req = _data_->_tmp1_;
	_data_->_tmp2_ = _data_->req;
	_data_->_state_ = 1;
	tuba_request_v2_exec (_data_->_tmp2_, tuba_instance_account_verify_credentials_ready, _data_);
	return FALSE;
	_state_1:
	_data_->_tmp3_ = tuba_request_v2_exec_finish (_data_->_tmp2_, _data_->_res_, NULL, &_data_->_inner_error0_);
	_data_->in_stream = _data_->_tmp3_;
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		g_task_return_error (_data_->_async_result, _data_->_inner_error0_);
		_g_object_unref0 (_data_->req);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp4_ = _data_->in_stream;
	_data_->_state_ = 2;
	tuba_instance_account_update_object (_data_->self, _data_->_tmp4_, tuba_instance_account_verify_credentials_ready, _data_);
	return FALSE;
	_state_2:
	tuba_instance_account_update_object_finish (_data_->self, _data_->_res_, &_data_->_inner_error0_);
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		g_task_return_error (_data_->_async_result, _data_->_inner_error0_);
		_g_object_unref0 (_data_->in_stream);
		_g_object_unref0 (_data_->req);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_g_object_unref0 (_data_->in_stream);
	_g_object_unref0 (_data_->req);
	g_task_return_pointer (_data_->_async_result, _data_, NULL);
	if (_data_->_state_ != 0) {
		while (!g_task_get_completed (_data_->_async_result)) {
			g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
		}
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}

static void
tuba_instance_account_update_object_data_free (gpointer _data)
{
	TubaInstanceAccountUpdateObjectData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->in_stream);
	_g_object_unref0 (_data_->self);
	g_slice_free (TubaInstanceAccountUpdateObjectData, _data_);
}

void
tuba_instance_account_update_object (TubaInstanceAccount* self,
                                     GInputStream* in_stream,
                                     GAsyncReadyCallback _callback_,
                                     gpointer _user_data_)
{
	TubaInstanceAccountUpdateObjectData* _data_;
	TubaInstanceAccount* _tmp0_;
	GInputStream* _tmp1_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (in_stream != NULL);
	_data_ = g_slice_new0 (TubaInstanceAccountUpdateObjectData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, tuba_instance_account_update_object_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	_tmp1_ = _g_object_ref0 (in_stream);
	_g_object_unref0 (_data_->in_stream);
	_data_->in_stream = _tmp1_;
	tuba_instance_account_update_object_co (_data_);
}

void
tuba_instance_account_update_object_finish (TubaInstanceAccount* self,
                                            GAsyncResult* _res_,
                                            GError** error)
{
	TubaInstanceAccountUpdateObjectData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), error);
	if (NULL == _data_) {
		return;
	}
}

static void
tuba_instance_account_update_object_ready (GObject* source_object,
                                           GAsyncResult* _res_,
                                           gpointer _user_data_)
{
	TubaInstanceAccountUpdateObjectData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	tuba_instance_account_update_object_co (_data_);
}

static gboolean
tuba_instance_account_update_object_co (TubaInstanceAccountUpdateObjectData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_state_ = 1;
	tuba_network_get_parser_from_inputstream_async (_data_->in_stream, NULL, tuba_instance_account_update_object_ready, _data_);
	return FALSE;
	_state_1:
	_data_->_tmp0_ = tuba_network_get_parser_from_inputstream_finish (_data_->_res_, &_data_->_inner_error0_);
	_data_->parser = _data_->_tmp0_;
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		g_task_return_error (_data_->_async_result, _data_->_inner_error0_);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp1_ = tuba_network;
	_data_->_tmp2_ = _data_->parser;
	_data_->_tmp3_ = tuba_network_parse_node (_data_->_tmp1_, _data_->_tmp2_);
	_data_->node = _data_->_tmp3_;
	_data_->_tmp4_ = _data_->node;
	_data_->_tmp5_ = tuba_api_account_from (_data_->_tmp4_, &_data_->_inner_error0_);
	_data_->updated = _data_->_tmp5_;
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		g_task_return_error (_data_->_async_result, _data_->_inner_error0_);
		__vala_JsonNode_free0 (_data_->node);
		_g_object_unref0 (_data_->parser);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp6_ = _data_->updated;
	tuba_entity_patch ((TubaEntity*) _data_->self, (GObject*) _data_->_tmp6_);
	_data_->_tmp7_ = tuba_instance_account_get_handle (_data_->self);
	_data_->_tmp8_ = _data_->_tmp7_;
	_data_->_tmp9_ = _data_->_tmp8_;
	_data_->_tmp10_ = string_to_string (_data_->_tmp9_);
	_data_->_tmp11_ = g_strconcat (_data_->_tmp10_, ": profile updated", NULL);
	_data_->_tmp12_ = _data_->_tmp11_;
	g_debug ("InstanceAccount.vala:369: %s", _data_->_tmp12_);
	_g_free0 (_data_->_tmp12_);
	_g_free0 (_data_->_tmp9_);
	_g_object_unref0 (_data_->updated);
	__vala_JsonNode_free0 (_data_->node);
	_g_object_unref0 (_data_->parser);
	g_task_return_pointer (_data_->_async_result, _data_, NULL);
	if (_data_->_state_ != 0) {
		while (!g_task_get_completed (_data_->_async_result)) {
			g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
		}
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}

static void
tuba_instance_account_resolve_data_free (gpointer _data)
{
	TubaInstanceAccountResolveData* _data_;
	_data_ = _data;
	_g_free0 (_data_->url);
	_g_object_unref0 (_data_->result);
	_g_object_unref0 (_data_->self);
	g_slice_free (TubaInstanceAccountResolveData, _data_);
}

void
tuba_instance_account_resolve (TubaInstanceAccount* self,
                               const gchar* url,
                               GAsyncReadyCallback _callback_,
                               gpointer _user_data_)
{
	TubaInstanceAccountResolveData* _data_;
	TubaInstanceAccount* _tmp0_;
	gchar* _tmp1_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (url != NULL);
	_data_ = g_slice_new0 (TubaInstanceAccountResolveData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, tuba_instance_account_resolve_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	_tmp1_ = g_strdup (url);
	_g_free0 (_data_->url);
	_data_->url = _tmp1_;
	tuba_instance_account_resolve_co (_data_);
}

TubaEntity*
tuba_instance_account_resolve_finish (TubaInstanceAccount* self,
                                      GAsyncResult* _res_,
                                      GError** error)
{
	TubaEntity* result;
	TubaInstanceAccountResolveData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), error);
	if (NULL == _data_) {
		return NULL;
	}
	result = _data_->result;
	_data_->result = NULL;
	return result;
}

static void
tuba_instance_account_resolve_ready (GObject* source_object,
                                     GAsyncResult* _res_,
                                     gpointer _user_data_)
{
	TubaInstanceAccountResolveData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	tuba_instance_account_resolve_co (_data_);
}

static gboolean
tuba_instance_account_resolve_co (TubaInstanceAccountResolveData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = string_to_string (_data_->url);
	_data_->_tmp1_ = g_strconcat ("Resolving URL: \"", _data_->_tmp0_, "\"…", NULL);
	_data_->_tmp2_ = _data_->_tmp1_;
	g_debug ("InstanceAccount.vala:373: %s", _data_->_tmp2_);
	_g_free0 (_data_->_tmp2_);
	_data_->_state_ = 1;
	tuba_api_search_results_request (_data_->url, _data_->self, tuba_instance_account_resolve_ready, _data_);
	return FALSE;
	_state_1:
	_data_->_tmp3_ = tuba_api_search_results_request_finish (_data_->_res_, &_data_->_inner_error0_);
	_data_->results = _data_->_tmp3_;
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		g_task_return_error (_data_->_async_result, _data_->_inner_error0_);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp4_ = _data_->results;
	_data_->_tmp5_ = tuba_api_search_results_first (_data_->_tmp4_, &_data_->_inner_error0_);
	_data_->entity = _data_->_tmp5_;
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		g_task_return_error (_data_->_async_result, _data_->_inner_error0_);
		_g_object_unref0 (_data_->results);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp6_ = _data_->entity;
	_data_->_tmp7_ = G_OBJECT_GET_CLASS ((GObject*) _data_->_tmp6_);
	_data_->_tmp8_ = G_OBJECT_CLASS_NAME (_data_->_tmp7_);
	_data_->_tmp9_ = string_to_string (_data_->_tmp8_);
	_data_->_tmp10_ = g_strconcat ("Found ", _data_->_tmp9_, NULL);
	_data_->_tmp11_ = _data_->_tmp10_;
	g_debug ("InstanceAccount.vala:376: %s", _data_->_tmp11_);
	_g_free0 (_data_->_tmp11_);
	_data_->result = _data_->entity;
	_g_object_unref0 (_data_->results);
	g_task_return_pointer (_data_->_async_result, _data_, NULL);
	if (_data_->_state_ != 0) {
		while (!g_task_get_completed (_data_->_async_result)) {
			g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
		}
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}

static void
tuba_instance_account_real_describe_kind (TubaInstanceAccount* self,
                                          const gchar* kind,
                                          TubaInstanceAccountKind* _result_,
                                          const gchar* actor_name,
                                          const gchar* callback_url,
                                          const gchar* other_data)
{
	TubaInstanceAccountKind _vala__result_ = {0};
	const gchar* _tmp0_;
	GQuark _tmp2_ = 0U;
	static GQuark _tmp1_label0 = 0;
	static GQuark _tmp1_label1 = 0;
	static GQuark _tmp1_label2 = 0;
	static GQuark _tmp1_label3 = 0;
	static GQuark _tmp1_label4 = 0;
	static GQuark _tmp1_label5 = 0;
	static GQuark _tmp1_label6 = 0;
	static GQuark _tmp1_label7 = 0;
	static GQuark _tmp1_label8 = 0;
	static GQuark _tmp1_label9 = 0;
	static GQuark _tmp1_label10 = 0;
	static GQuark _tmp1_label11 = 0;
	static GQuark _tmp1_label12 = 0;
	static GQuark _tmp1_label13 = 0;
	static GQuark _tmp1_label14 = 0;
	static GQuark _tmp1_label15 = 0;
	static GQuark _tmp1_label16 = 0;
	static GQuark _tmp1_label17 = 0;
	static GQuark _tmp1_label18 = 0;
	static GQuark _tmp1_label19 = 0;
	static GQuark _tmp1_label20 = 0;
	_tmp0_ = kind;
	_tmp2_ = (NULL == _tmp0_) ? 0 : g_quark_from_string (_tmp0_);
	if (_tmp2_ == ((0 != _tmp1_label0) ? _tmp1_label0 : (_tmp1_label0 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_MENTION)))) {
		switch (0) {
			default:
			{
				gchar* _tmp3_;
				gchar* _tmp4_;
				gchar* _tmp5_;
				TubaInstanceAccountKind _tmp6_ = {0};
				_tmp3_ = g_strdup ("tuba-chat-symbolic");
				_tmp4_ = g_strdup_printf (_ ("%s mentioned you"), actor_name);
				_tmp5_ = g_strdup (callback_url);
				_g_free0 (_tmp6_.icon);
				_tmp6_.icon = _tmp3_;
				_g_free0 (_tmp6_.description);
				_tmp6_.description = _tmp4_;
				_g_free0 (_tmp6_.url);
				_tmp6_.url = _tmp5_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp6_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label1) ? _tmp1_label1 : (_tmp1_label1 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_REBLOG)))) {
		switch (0) {
			default:
			{
				gchar* _tmp7_;
				gchar* _tmp8_;
				gchar* _tmp9_;
				TubaInstanceAccountKind _tmp10_ = {0};
				_tmp7_ = g_strdup ("tuba-media-playlist-repeat-symbolic");
				_tmp8_ = g_strdup_printf (_ ("%s boosted your post"), actor_name);
				_tmp9_ = g_strdup (callback_url);
				_g_free0 (_tmp10_.icon);
				_tmp10_.icon = _tmp7_;
				_g_free0 (_tmp10_.description);
				_tmp10_.description = _tmp8_;
				_g_free0 (_tmp10_.url);
				_tmp10_.url = _tmp9_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp10_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label2) ? _tmp1_label2 : (_tmp1_label2 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_REMOTE_REBLOG)))) {
		switch (0) {
			default:
			{
				gchar* _tmp11_;
				gchar* _tmp12_;
				gchar* _tmp13_;
				TubaInstanceAccountKind _tmp14_ = {0};
				_tmp11_ = g_strdup ("tuba-media-playlist-repeat-symbolic");
				_tmp12_ = g_strdup_printf (_ ("%s boosted"), actor_name);
				_tmp13_ = g_strdup (callback_url);
				_g_free0 (_tmp14_.icon);
				_tmp14_.icon = _tmp11_;
				_g_free0 (_tmp14_.description);
				_tmp14_.description = _tmp12_;
				_g_free0 (_tmp14_.url);
				_tmp14_.url = _tmp13_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp14_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label3) ? _tmp1_label3 : (_tmp1_label3 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_FAVOURITE)))) {
		switch (0) {
			default:
			{
				gchar* _tmp15_;
				gchar* _tmp16_;
				gchar* _tmp17_;
				TubaInstanceAccountKind _tmp18_ = {0};
				_tmp15_ = g_strdup ("tuba-starred-symbolic");
				_tmp16_ = g_strdup_printf (_ ("%s favorited your post"), actor_name);
				_tmp17_ = g_strdup (callback_url);
				_g_free0 (_tmp18_.icon);
				_tmp18_.icon = _tmp15_;
				_g_free0 (_tmp18_.description);
				_tmp18_.description = _tmp16_;
				_g_free0 (_tmp18_.url);
				_tmp18_.url = _tmp17_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp18_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label4) ? _tmp1_label4 : (_tmp1_label4 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_FOLLOW)))) {
		switch (0) {
			default:
			{
				gchar* _tmp19_;
				gchar* _tmp20_;
				gchar* _tmp21_;
				TubaInstanceAccountKind _tmp22_ = {0};
				_tmp19_ = g_strdup ("contact-new-symbolic");
				_tmp20_ = g_strdup_printf (_ ("%s now follows you"), actor_name);
				_tmp21_ = g_strdup (callback_url);
				_g_free0 (_tmp22_.icon);
				_tmp22_.icon = _tmp19_;
				_g_free0 (_tmp22_.description);
				_tmp22_.description = _tmp20_;
				_g_free0 (_tmp22_.url);
				_tmp22_.url = _tmp21_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp22_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label5) ? _tmp1_label5 : (_tmp1_label5 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_FOLLOW_REQUEST)))) {
		switch (0) {
			default:
			{
				gchar* _tmp23_;
				gchar* _tmp24_;
				gchar* _tmp25_;
				TubaInstanceAccountKind _tmp26_ = {0};
				_tmp23_ = g_strdup ("contact-new-symbolic");
				_tmp24_ = g_strdup_printf (_ ("%s wants to follow you"), actor_name);
				_tmp25_ = g_strdup (callback_url);
				_g_free0 (_tmp26_.icon);
				_tmp26_.icon = _tmp23_;
				_g_free0 (_tmp26_.description);
				_tmp26_.description = _tmp24_;
				_g_free0 (_tmp26_.url);
				_tmp26_.url = _tmp25_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp26_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label6) ? _tmp1_label6 : (_tmp1_label6 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_POLL)))) {
		switch (0) {
			default:
			{
				gchar* _tmp27_;
				gchar* _tmp28_;
				TubaInstanceAccountKind _tmp29_ = {0};
				_tmp27_ = g_strdup ("tuba-check-round-outline-symbolic");
				_tmp28_ = g_strdup (_ ("Poll results"));
				_g_free0 (_tmp29_.icon);
				_tmp29_.icon = _tmp27_;
				_g_free0 (_tmp29_.description);
				_tmp29_.description = _tmp28_;
				_g_free0 (_tmp29_.url);
				_tmp29_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp29_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label7) ? _tmp1_label7 : (_tmp1_label7 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_EDITED)))) {
		switch (0) {
			default:
			{
				gchar* _tmp30_;
				gchar* _tmp31_;
				TubaInstanceAccountKind _tmp32_ = {0};
				_tmp30_ = g_strdup ("document-edit-symbolic");
				_tmp31_ = g_strdup_printf (_ ("%s edited a post"), actor_name);
				_g_free0 (_tmp32_.icon);
				_tmp32_.icon = _tmp30_;
				_g_free0 (_tmp32_.description);
				_tmp32_.description = _tmp31_;
				_g_free0 (_tmp32_.url);
				_tmp32_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp32_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label8) ? _tmp1_label8 : (_tmp1_label8 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_REPLY)))) {
		switch (0) {
			default:
			{
				gchar* reply_text = NULL;
				gchar* _tmp35_;
				const gchar* _tmp36_;
				gchar* _tmp37_;
				TubaInstanceAccountKind _tmp38_ = {0};
				if (actor_name == NULL) {
					gchar* _tmp33_;
					_tmp33_ = g_strdup (_ ("In Reply"));
					_g_free0 (reply_text);
					reply_text = _tmp33_;
				} else {
					gchar* _tmp34_;
					_tmp34_ = g_strdup_printf (_ ("In Reply to %s"), actor_name);
					_g_free0 (reply_text);
					reply_text = _tmp34_;
				}
				_tmp35_ = g_strdup ("tuba-reply-sender-symbolic");
				_tmp36_ = reply_text;
				_tmp37_ = g_strdup (_tmp36_);
				_g_free0 (_tmp38_.icon);
				_tmp38_.icon = _tmp35_;
				_g_free0 (_tmp38_.description);
				_tmp38_.description = _tmp37_;
				_g_free0 (_tmp38_.url);
				_tmp38_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp38_;
				_g_free0 (reply_text);
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label9) ? _tmp1_label9 : (_tmp1_label9 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_ADMIN_SIGNUP)))) {
		switch (0) {
			default:
			{
				gchar* _tmp39_;
				gchar* _tmp40_;
				TubaInstanceAccountKind _tmp41_ = {0};
				_tmp39_ = g_strdup ("tuba-build-alt-symbolic");
				_tmp40_ = g_strdup_printf (_ ("%s signed up"), actor_name);
				_g_free0 (_tmp41_.icon);
				_tmp41_.icon = _tmp39_;
				_g_free0 (_tmp41_.description);
				_tmp41_.description = _tmp40_;
				_g_free0 (_tmp41_.url);
				_tmp41_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp41_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label10) ? _tmp1_label10 : (_tmp1_label10 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_SEVERED_RELATIONSHIPS)))) {
		switch (0) {
			default:
			{
				gchar* _tmp42_;
				gchar* _tmp43_;
				TubaInstanceAccountKind _tmp44_ = {0};
				_tmp42_ = g_strdup ("tuba-heart-broken-symbolic");
				_tmp43_ = g_strdup (_ ("Some of your relationships got severed"));
				_g_free0 (_tmp44_.icon);
				_tmp44_.icon = _tmp42_;
				_g_free0 (_tmp44_.description);
				_tmp44_.description = _tmp43_;
				_g_free0 (_tmp44_.url);
				_tmp44_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp44_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label11) ? _tmp1_label11 : (_tmp1_label11 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_ANNUAL_REPORT)))) {
		switch (0) {
			default:
			{
				gchar* _tmp45_;
				gchar* _tmp46_;
				TubaInstanceAccountKind _tmp47_ = {0};
				_tmp45_ = g_strdup ("tuba-heart-broken-symbolic");
				_tmp46_ = g_strdup_printf (_ ("Your %s #FediWrapped is ready!"), other_data);
				_g_free0 (_tmp47_.icon);
				_tmp47_.icon = _tmp45_;
				_g_free0 (_tmp47_.description);
				_tmp47_.description = _tmp46_;
				_g_free0 (_tmp47_.url);
				_tmp47_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp47_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label12) ? _tmp1_label12 : (_tmp1_label12 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_MODERATION_WARNING)))) {
		switch (0) {
			default:
			{
				gchar* _tmp48_;
				gchar* _tmp49_;
				TubaInstanceAccountKind _tmp50_ = {0};
				_tmp48_ = g_strdup ("tuba-police-badge2-symbolic");
				_tmp49_ = g_strdup (_ ("Your account has received a moderation warning"));
				_g_free0 (_tmp50_.icon);
				_tmp50_.icon = _tmp48_;
				_g_free0 (_tmp50_.description);
				_tmp50_.description = _tmp49_;
				_g_free0 (_tmp50_.url);
				_tmp50_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp50_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label13) ? _tmp1_label13 : (_tmp1_label13 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_ADMIN_REPORT)))) {
		switch (0) {
			default:
			{
				gchar* _tmp51_;
				gchar* _tmp52_;
				TubaInstanceAccountKind _tmp53_ = {0};
				_tmp51_ = g_strdup ("tuba-build-alt-symbolic");
				_tmp52_ = g_strdup (_ ("Received a new report"));
				_g_free0 (_tmp53_.icon);
				_tmp53_.icon = _tmp51_;
				_g_free0 (_tmp53_.description);
				_tmp53_.description = _tmp52_;
				_g_free0 (_tmp53_.url);
				_tmp53_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp53_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label14) ? _tmp1_label14 : (_tmp1_label14 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_STATUS)))) {
		switch (0) {
			default:
			{
				gchar* _tmp54_;
				gchar* _tmp55_;
				TubaInstanceAccountKind _tmp56_ = {0};
				_tmp54_ = g_strdup ("tuba-bell-outline-symbolic");
				_tmp55_ = g_strdup_printf (_ ("%s just posted"), actor_name);
				_g_free0 (_tmp56_.icon);
				_tmp56_.icon = _tmp54_;
				_g_free0 (_tmp56_.description);
				_tmp56_.description = _tmp55_;
				_g_free0 (_tmp56_.url);
				_tmp56_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp56_;
				break;
			}
		}
	} else if ((_tmp2_ == ((0 != _tmp1_label15) ? _tmp1_label15 : (_tmp1_label15 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_PLEROMA_REACTION)))) || (_tmp2_ == ((0 != _tmp1_label16) ? _tmp1_label16 : (_tmp1_label16 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_REACTION))))) {
		switch (0) {
			default:
			{
				gchar* body = NULL;
				gchar* _tmp59_;
				const gchar* _tmp60_;
				gchar* _tmp61_;
				gchar* _tmp62_;
				TubaInstanceAccountKind _tmp63_ = {0};
				if (other_data == NULL) {
					gchar* _tmp57_;
					_tmp57_ = g_strdup_printf (_ ("%s reacted to your post"), actor_name);
					_g_free0 (body);
					body = _tmp57_;
				} else {
					gchar* _tmp58_;
					_tmp58_ = g_strdup_printf (_ ("%s reacted to your post with %s"), actor_name, other_data);
					_g_free0 (body);
					body = _tmp58_;
				}
				_tmp59_ = g_strdup ("tuba-smile-symbolic");
				_tmp60_ = body;
				_tmp61_ = g_strdup (_tmp60_);
				_tmp62_ = g_strdup (callback_url);
				_g_free0 (_tmp63_.icon);
				_tmp63_.icon = _tmp59_;
				_g_free0 (_tmp63_.description);
				_tmp63_.description = _tmp61_;
				_g_free0 (_tmp63_.url);
				_tmp63_.url = _tmp62_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp63_;
				_g_free0 (body);
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label17) ? _tmp1_label17 : (_tmp1_label17 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_QUOTE)))) {
		switch (0) {
			default:
			{
				gchar* _tmp64_;
				gchar* _tmp65_;
				gchar* _tmp66_;
				TubaInstanceAccountKind _tmp67_ = {0};
				_tmp64_ = g_strdup ("tuba-quotation-symbolic");
				_tmp65_ = g_strdup_printf (_ ("%s quoted your post"), actor_name);
				_tmp66_ = g_strdup (callback_url);
				_g_free0 (_tmp67_.icon);
				_tmp67_.icon = _tmp64_;
				_g_free0 (_tmp67_.description);
				_tmp67_.description = _tmp65_;
				_g_free0 (_tmp67_.url);
				_tmp67_.url = _tmp66_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp67_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label18) ? _tmp1_label18 : (_tmp1_label18 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_QUOTE_UPDATE)))) {
		switch (0) {
			default:
			{
				gchar* _tmp68_;
				gchar* _tmp69_;
				gchar* _tmp70_;
				TubaInstanceAccountKind _tmp71_ = {0};
				_tmp68_ = g_strdup ("tuba-quotation-symbolic");
				_tmp69_ = g_strdup_printf (_ ("%s edited a post you have quoted"), actor_name);
				_tmp70_ = g_strdup (callback_url);
				_g_free0 (_tmp71_.icon);
				_tmp71_.icon = _tmp68_;
				_g_free0 (_tmp71_.description);
				_tmp71_.description = _tmp69_;
				_g_free0 (_tmp71_.url);
				_tmp71_.url = _tmp70_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp71_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label19) ? _tmp1_label19 : (_tmp1_label19 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_COLLECTION_ADDED)))) {
		switch (0) {
			default:
			{
				gchar* _tmp72_;
				gchar* _tmp73_;
				gchar* _tmp74_;
				TubaInstanceAccountKind _tmp75_ = {0};
				_tmp72_ = g_strdup ("tuba-shapes-symbolic");
				_tmp73_ = g_strdup_printf (_ ("%s added you to a collection"), actor_name);
				_tmp74_ = g_strdup (callback_url);
				_g_free0 (_tmp75_.icon);
				_tmp75_.icon = _tmp72_;
				_g_free0 (_tmp75_.description);
				_tmp75_.description = _tmp73_;
				_g_free0 (_tmp75_.url);
				_tmp75_.url = _tmp74_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp75_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label20) ? _tmp1_label20 : (_tmp1_label20 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_COLLECTION_EDITED)))) {
		switch (0) {
			default:
			{
				gchar* _tmp76_;
				gchar* _tmp77_;
				gchar* _tmp78_;
				TubaInstanceAccountKind _tmp79_ = {0};
				_tmp76_ = g_strdup ("tuba-shapes-symbolic");
				_tmp77_ = g_strdup_printf (_ ("%s edited a collection you are in"), actor_name);
				_tmp78_ = g_strdup (callback_url);
				_g_free0 (_tmp79_.icon);
				_tmp79_.icon = _tmp76_;
				_g_free0 (_tmp79_.description);
				_tmp79_.description = _tmp77_;
				_g_free0 (_tmp79_.url);
				_tmp79_.url = _tmp78_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp79_;
				break;
			}
		}
	} else {
		switch (0) {
			default:
			{
				TubaInstanceAccountKind _tmp80_ = {0};
				_g_free0 (_tmp80_.icon);
				_tmp80_.icon = NULL;
				_g_free0 (_tmp80_.description);
				_tmp80_.description = NULL;
				_g_free0 (_tmp80_.url);
				_tmp80_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp80_;
				break;
			}
		}
	}
	if (_result_) {
		*_result_ = _vala__result_;
	} else {
		tuba_instance_account_kind_destroy (&_vala__result_);
	}
}

void
tuba_instance_account_describe_kind (TubaInstanceAccount* self,
                                     const gchar* kind,
                                     TubaInstanceAccountKind* _result_,
                                     const gchar* actor_name,
                                     const gchar* callback_url,
                                     const gchar* other_data)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->describe_kind) {
		_klass_->describe_kind (self, kind, _result_, actor_name, callback_url, other_data);
	}
}

static void
tuba_instance_account_real_register_known_places (TubaInstanceAccount* self,
                                                  GListStore* places)
{
	g_return_if_fail (places != NULL);
}

void
tuba_instance_account_register_known_places (TubaInstanceAccount* self,
                                             GListStore* places)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->register_known_places) {
		_klass_->register_known_places (self, places);
	}
}

static void
tuba_instance_account_real_register_extra (TubaInstanceAccount* self,
                                           GListStore* places,
                                           TubaPlace** extra,
                                           gint extra_length1)
{
	g_return_if_fail (places != NULL);
}

void
tuba_instance_account_register_extra (TubaInstanceAccount* self,
                                      GListStore* places,
                                      TubaPlace** extra,
                                      gint extra_length1)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->register_extra) {
		_klass_->register_extra (self, places, extra, extra_length1);
	}
}

static void
tuba_instance_account_gather_instance_info_data_free (gpointer _data)
{
	TubaInstanceAccountGatherInstanceInfoData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->self);
	g_slice_free (TubaInstanceAccountGatherInstanceInfoData, _data_);
}

void
tuba_instance_account_gather_instance_info (TubaInstanceAccount* self,
                                            GAsyncReadyCallback _callback_,
                                            gpointer _user_data_)
{
	TubaInstanceAccountGatherInstanceInfoData* _data_;
	TubaInstanceAccount* _tmp0_;
	g_return_if_fail (self != NULL);
	_data_ = g_slice_new0 (TubaInstanceAccountGatherInstanceInfoData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, tuba_instance_account_gather_instance_info_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	tuba_instance_account_gather_instance_info_co (_data_);
}

void
tuba_instance_account_gather_instance_info_finish (TubaInstanceAccount* self,
                                                   GAsyncResult* _res_)
{
	TubaInstanceAccountGatherInstanceInfoData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), NULL);
}

static void
tuba_instance_account_gather_instance_info_ready (GObject* source_object,
                                                  GAsyncResult* _res_,
                                                  gpointer _user_data_)
{
	TubaInstanceAccountGatherInstanceInfoData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	tuba_instance_account_gather_instance_info_co (_data_);
}

static gchar**
_vala_array_dup34 (gchar** self,
                   gssize length)
{
	if (length >= 0) {
		gchar** result;
		gssize i;
		result = g_new0 (gchar*, length + 1);
		for (i = 0; i < length; i++) {
			gchar* _tmp0_;
			_tmp0_ = g_strdup (self[i]);
			result[i] = _tmp0_;
		}
		return result;
	}
	return NULL;
}

static gboolean
_vala_string_array_contains (gchar* * stack,
                             gssize stack_length,
                             const gchar* needle)
{
	gssize i;
	for (i = 0; i < stack_length; i++) {
		if (g_strcmp0 (stack[i], needle) == 0) {
			return TRUE;
		}
	}
	return FALSE;
}

static gboolean
string_contains (const gchar* self,
                 const gchar* needle)
{
	gchar* _tmp0_;
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	g_return_val_if_fail (needle != NULL, FALSE);
	_tmp0_ = strstr ((gchar*) self, (gchar*) needle);
	result = _tmp0_ != NULL;
	return result;
}

static gboolean
tuba_instance_account_gather_instance_info_co (TubaInstanceAccountGatherInstanceInfoData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = _data_->self->priv->_instance_info;
	if (_data_->_tmp0_ != NULL) {
		g_task_return_pointer (_data_->_async_result, _data_, NULL);
		if (_data_->_state_ != 0) {
			while (!g_task_get_completed (_data_->_async_result)) {
				g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
			}
		}
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp1_ = _g_object_ref0 (_data_->self);
	_data_->_tmp2_ = NULL;
	_data_->_tmp2_ = tuba_request_v2_new ("/api/v1/instance", TUBA_REQUEST_V2_METHOD_GET);
	tuba_request_v2_set_account (_data_->_tmp2_, _data_->_tmp1_);
	_g_object_unref0 (_data_->_tmp1_);
	_data_->req = _data_->_tmp2_;
	{
		_data_->_tmp3_ = _data_->req;
		_data_->_state_ = 1;
		tuba_request_v2_exec (_data_->_tmp3_, tuba_instance_account_gather_instance_info_ready, _data_);
		return FALSE;
		_state_1:
		_data_->_tmp4_ = tuba_request_v2_exec_finish (_data_->_tmp3_, _data_->_res_, NULL, &_data_->_inner_error0_);
		_data_->in_stream = _data_->_tmp4_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
		_data_->_tmp5_ = _data_->in_stream;
		_data_->_state_ = 2;
		tuba_network_get_parser_from_inputstream_async (_data_->_tmp5_, NULL, tuba_instance_account_gather_instance_info_ready, _data_);
		return FALSE;
		_state_2:
		_data_->_tmp6_ = tuba_network_get_parser_from_inputstream_finish (_data_->_res_, &_data_->_inner_error0_);
		_data_->parser = _data_->_tmp6_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			_g_object_unref0 (_data_->in_stream);
			goto __catch0_g_error;
		}
		_data_->_tmp7_ = tuba_network;
		_data_->_tmp8_ = _data_->parser;
		_data_->_tmp9_ = tuba_network_parse_node (_data_->_tmp7_, _data_->_tmp8_);
		_data_->node = _data_->_tmp9_;
		_data_->_tmp10_ = _data_->node;
		if (_data_->_tmp10_ == NULL) {
			__vala_JsonNode_free0 (_data_->node);
			_g_object_unref0 (_data_->parser);
			_g_object_unref0 (_data_->in_stream);
			_g_object_unref0 (_data_->req);
			g_task_return_pointer (_data_->_async_result, _data_, NULL);
			if (_data_->_state_ != 0) {
				while (!g_task_get_completed (_data_->_async_result)) {
					g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
				}
			}
			g_object_unref (_data_->_async_result);
			return FALSE;
		}
		_data_->_tmp12_ = _data_->node;
		_data_->_tmp13_ = tuba_api_instance_from (_data_->_tmp12_, &_data_->_inner_error0_);
		_data_->_tmp11_ = _data_->_tmp13_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			__vala_JsonNode_free0 (_data_->node);
			_g_object_unref0 (_data_->parser);
			_g_object_unref0 (_data_->in_stream);
			goto __catch0_g_error;
		}
		tuba_instance_account_set_instance_info (_data_->self, _data_->_tmp11_);
		_data_->_tmp14_ = _data_->self->priv->_instance_info;
		_data_->_tmp16_ = 0;
		_data_->_tmp15_ = tuba_api_instance_get_compat_supported_mime_types (_data_->_tmp14_, &_data_->_tmp16_);
		_data_->_tmp15__length1 = _data_->_tmp16_;
		_data_->_tmp17_ = _data_->_tmp15_;
		_data_->_tmp17__length1 = _data_->_tmp15__length1;
		_data_->_tmp18_ = (_data_->_tmp17_ != NULL) ? _vala_array_dup34 (_data_->_tmp17_, _data_->_tmp17__length1) : _data_->_tmp17_;
		_data_->_tmp18__length1 = _data_->_tmp17__length1;
		_data_->content_types = _data_->_tmp18_;
		_data_->content_types_length1 = _data_->_tmp18__length1;
		_data_->_content_types_size_ = _data_->content_types_length1;
		_data_->_tmp19_ = _data_->content_types;
		_data_->_tmp19__length1 = _data_->content_types_length1;
		if (_data_->_tmp19_ != NULL) {
			_data_->_tmp20_ = _data_->self->supported_mime_types;
			g_list_store_remove_all (_data_->_tmp20_);
			_data_->_tmp21_ = _data_->content_types;
			_data_->_tmp21__length1 = _data_->content_types_length1;
			{
				_data_->content_type_collection_length1 = 0;
				_data_->_content_type_collection_size_ = 0;
				_data_->content_type_collection = _data_->_tmp21_;
				_data_->content_type_collection_length1 = _data_->_tmp21__length1;
				for (_data_->content_type_it = 0; _data_->content_type_it < _data_->content_type_collection_length1; _data_->content_type_it = _data_->content_type_it + 1) {
					_data_->_tmp22_ = g_strdup (_data_->content_type_collection[_data_->content_type_it]);
					_data_->content_type = _data_->_tmp22_;
					{
						_data_->_tmp23_ = _data_->self->supported_mime_types;
						_data_->_tmp24_ = _data_->content_type;
						_data_->_tmp25_ = tuba_instance_account_status_content_type_new (_data_->_tmp24_);
						_data_->_tmp26_ = _data_->_tmp25_;
						g_list_store_append (_data_->_tmp23_, (GObject*) _data_->_tmp26_);
						_g_object_unref0 (_data_->_tmp26_);
						_g_free0 (_data_->content_type);
					}
				}
			}
		}
		_data_->_tmp27_ = _data_->self->priv->_tuba_instance_features;
		_data_->new_flags = _data_->_tmp27_;
		if (!((_data_->new_flags & TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GOTOSOCIAL) == TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GOTOSOCIAL)) {
			_data_->_tmp29_ = _data_->self->priv->_backend;
			_data_->_tmp30_ = g_utf8_strdown (_data_->_tmp29_, (gssize) -1);
			_data_->_tmp31_ = _data_->_tmp30_;
			_data_->_tmp28_ = g_strcmp0 (_data_->_tmp31_, "gotosocial") == 0;
			_g_free0 (_data_->_tmp31_);
		} else {
			_data_->_tmp28_ = FALSE;
		}
		if (_data_->_tmp28_) {
			_data_->new_flags |= TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GOTOSOCIAL;
		}
		_data_->_tmp32_ = _data_->self->priv->_instance_info;
		_data_->_tmp33_ = tuba_api_instance_get_pleroma (_data_->_tmp32_);
		_data_->_tmp34_ = _data_->_tmp33_;
		if (_data_->_tmp34_ == NULL) {
			tuba_instance_account_gather_v2_instance_info (_data_->self, NULL, NULL);
		} else {
			_data_->_tmp36_ = _data_->self->priv->_instance_info;
			_data_->_tmp37_ = tuba_api_instance_get_pleroma (_data_->_tmp36_);
			_data_->_tmp38_ = _data_->_tmp37_;
			_data_->_tmp39_ = tuba_api_pleroma_instance_get_metadata (_data_->_tmp38_);
			_data_->_tmp40_ = _data_->_tmp39_;
			if (_data_->_tmp40_ != NULL) {
				_data_->_tmp41_ = _data_->self->priv->_instance_info;
				_data_->_tmp42_ = tuba_api_instance_get_pleroma (_data_->_tmp41_);
				_data_->_tmp43_ = _data_->_tmp42_;
				_data_->_tmp44_ = tuba_api_pleroma_instance_get_metadata (_data_->_tmp43_);
				_data_->_tmp45_ = _data_->_tmp44_;
				_data_->_tmp47_ = 0;
				_data_->_tmp46_ = tuba_api_pleroma_instance_metadata_get_features (_data_->_tmp45_, &_data_->_tmp47_);
				_data_->_tmp46__length1 = _data_->_tmp47_;
				_data_->_tmp48_ = _data_->_tmp46_;
				_data_->_tmp48__length1 = _data_->_tmp46__length1;
				_data_->_tmp35_ = _data_->_tmp48_ != NULL;
			} else {
				_data_->_tmp35_ = FALSE;
			}
			if (_data_->_tmp35_) {
				_data_->_tmp49_ = _data_->self->priv->_instance_info;
				_data_->_tmp50_ = _data_->self->priv->_instance_info;
				_data_->_tmp51_ = tuba_api_instance_get_pleroma (_data_->_tmp50_);
				_data_->_tmp52_ = _data_->_tmp51_;
				_data_->_tmp53_ = tuba_api_pleroma_instance_get_metadata (_data_->_tmp52_);
				_data_->_tmp54_ = _data_->_tmp53_;
				_data_->_tmp56_ = 0;
				_data_->_tmp55_ = tuba_api_pleroma_instance_metadata_get_features (_data_->_tmp54_, &_data_->_tmp56_);
				_data_->_tmp55__length1 = _data_->_tmp56_;
				_data_->_tmp57_ = _data_->_tmp55_;
				_data_->_tmp57__length1 = _data_->_tmp55__length1;
				tuba_api_instance_set_tuba_can_translate (_data_->_tmp49_, _vala_string_array_contains (_data_->_tmp57_, _data_->_tmp57__length1, "akkoma:machine_translation"));
				_data_->_tmp59_ = _data_->self->priv->_instance_info;
				_data_->_tmp60_ = tuba_api_instance_get_supports_quote_posting (_data_->_tmp59_);
				_data_->_tmp61_ = _data_->_tmp60_;
				if (_data_->_tmp61_) {
					_data_->_tmp58_ = _data_->new_flags | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_QUOTE;
				} else {
					_data_->_tmp58_ = _data_->new_flags & (~TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_QUOTE);
				}
				_data_->new_flags = _data_->_tmp58_;
				_data_->_tmp63_ = _data_->self->priv->_instance_info;
				_data_->_tmp64_ = tuba_api_instance_get_tuba_can_translate (_data_->_tmp63_);
				_data_->_tmp65_ = _data_->_tmp64_;
				if (_data_->_tmp65_) {
					_data_->_tmp62_ = _data_->new_flags | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_TRANSLATION;
				} else {
					_data_->_tmp62_ = _data_->new_flags & (~TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_TRANSLATION);
				}
				_data_->new_flags = _data_->_tmp62_;
				_data_->_tmp66_ = _data_->self->priv->_instance_info;
				_data_->_tmp67_ = tuba_api_instance_get_supports_bubble (_data_->_tmp66_);
				_data_->_tmp68_ = _data_->_tmp67_;
				if (_data_->_tmp68_) {
					_data_->new_flags |= TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_BUBBLE;
				}
			}
		}
		_data_->_tmp70_ = _data_->self->priv->_instance_info;
		_data_->_tmp71_ = tuba_api_instance_get_version (_data_->_tmp70_);
		_data_->_tmp72_ = _data_->_tmp71_;
		if (_data_->_tmp72_ != NULL) {
			_data_->_tmp69_ = !((_data_->new_flags & TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY) == TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY);
		} else {
			_data_->_tmp69_ = FALSE;
		}
		if (_data_->_tmp69_) {
			_data_->_tmp73_ = _data_->self->priv->_instance_info;
			_data_->_tmp74_ = tuba_api_instance_get_version (_data_->_tmp73_);
			_data_->_tmp75_ = _data_->_tmp74_;
			if (string_contains (_data_->_tmp75_, "Pleroma ")) {
				_data_->new_flags |= (((TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_EMOJI_REACTIONS | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_FEATURE_TAGS) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ENDORSE_USERS) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_MUTUALS) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY;
			} else {
				_data_->_tmp76_ = _data_->self->priv->_instance_info;
				_data_->_tmp77_ = tuba_api_instance_get_version (_data_->_tmp76_);
				_data_->_tmp78_ = _data_->_tmp77_;
				if (string_contains (_data_->_tmp78_, "Iceshrimp.NET/")) {
					_data_->new_flags |= ((TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ICESHRIMP | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_EMOJI_REACTIONS) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_BUBBLE;
				} else {
					_data_->_tmp79_ = _data_->self->priv->_instance_info;
					_data_->_tmp80_ = tuba_api_instance_get_version (_data_->_tmp79_);
					_data_->_tmp81_ = _data_->_tmp80_;
					if (string_contains (_data_->_tmp81_, "+glitch")) {
						_data_->new_flags |= ((TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GLITCH | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_FEATURE_TAGS) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ENDORSE_USERS;
					} else {
						_data_->_tmp82_ = _data_->self->priv->_instance_info;
						_data_->_tmp83_ = tuba_api_instance_get_version (_data_->_tmp82_);
						_data_->_tmp84_ = _data_->_tmp83_;
						if (string_contains (_data_->_tmp84_, "+hometown")) {
							_data_->new_flags |= (TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_FEATURE_TAGS) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ENDORSE_USERS;
						} else {
							_data_->_tmp85_ = _data_->self->priv->_instance_info;
							_data_->_tmp86_ = tuba_api_instance_get_version (_data_->_tmp85_);
							_data_->_tmp87_ = _data_->_tmp86_;
							if (string_contains (_data_->_tmp87_, "Akkoma ")) {
								_data_->new_flags |= TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_EMOJI_REACTIONS | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY;
							}
						}
					}
				}
			}
		}
		tuba_instance_account_tuba_instance_features_update_and_save (_data_->self, _data_->new_flags);
		_data_->_tmp89_ = _data_->self->priv->_instance_info;
		_data_->_tmp90_ = tuba_api_instance_get_urls (_data_->_tmp89_);
		_data_->_tmp91_ = _data_->_tmp90_;
		if (_data_->_tmp91_ != NULL) {
			_data_->_tmp92_ = _data_->self->priv->_instance_info;
			_data_->_tmp93_ = tuba_api_instance_get_urls (_data_->_tmp92_);
			_data_->_tmp94_ = _data_->_tmp93_;
			_data_->_tmp95_ = tuba_api_instance_urls_get_streaming_api (_data_->_tmp94_);
			_data_->_tmp96_ = _data_->_tmp95_;
			_data_->_tmp88_ = _data_->_tmp96_ != NULL;
		} else {
			_data_->_tmp88_ = FALSE;
		}
		if (_data_->_tmp88_) {
			_data_->_tmp97_ = _data_->self->priv->_instance_info;
			_data_->_tmp98_ = tuba_api_instance_get_urls (_data_->_tmp97_);
			_data_->_tmp99_ = _data_->_tmp98_;
			_data_->_tmp100_ = tuba_api_instance_urls_get_streaming_api (_data_->_tmp99_);
			_data_->_tmp101_ = _data_->_tmp100_;
			tuba_instance_account_tuba_update_streaming_url (_data_->self, _data_->_tmp101_);
		}
		_data_->_tmp102_ = tuba_app;
		tuba_application_handle_share (_data_->_tmp102_);
		tuba_instance_account_bump_sidebar_items (_data_->self);
		_data_->content_types = (_vala_array_free (_data_->content_types, _data_->content_types_length1, (GDestroyNotify) g_free), NULL);
		_g_object_unref0 (_data_->_tmp11_);
		__vala_JsonNode_free0 (_data_->node);
		_g_object_unref0 (_data_->parser);
		_g_object_unref0 (_data_->in_stream);
	}
	goto __finally0;
	__catch0_g_error:
	{
		_data_->e = _data_->_inner_error0_;
		_data_->_inner_error0_ = NULL;
		_data_->_tmp103_ = _data_->e;
		_data_->_tmp104_ = g_strdup_printf ("%i", _data_->_tmp103_->code);
		_data_->_tmp105_ = _data_->_tmp104_;
		_data_->_tmp106_ = _data_->e;
		_data_->_tmp107_ = _data_->_tmp106_->message;
		_data_->_tmp108_ = string_to_string (_data_->_tmp107_);
		_data_->_tmp109_ = g_strconcat ("Couldn't fetch instance: ", _data_->_tmp105_, " ", _data_->_tmp108_, NULL);
		_data_->_tmp110_ = _data_->_tmp109_;
		g_warning ("InstanceAccount.vala:741: %s", _data_->_tmp110_);
		_g_free0 (_data_->_tmp110_);
		_g_free0 (_data_->_tmp105_);
		_g_error_free0 (_data_->e);
	}
	__finally0:
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		_g_object_unref0 (_data_->req);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error0_->message, g_quark_to_string (_data_->_inner_error0_->domain), _data_->_inner_error0_->code);
		g_clear_error (&_data_->_inner_error0_);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_g_object_unref0 (_data_->req);
	g_task_return_pointer (_data_->_async_result, _data_, NULL);
	if (_data_->_state_ != 0) {
		while (!g_task_get_completed (_data_->_async_result)) {
			g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
		}
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}

static void
tuba_instance_account_real_bump_sidebar_items (TubaInstanceAccount* self)
{
}

void
tuba_instance_account_bump_sidebar_items (TubaInstanceAccount* self)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->bump_sidebar_items) {
		_klass_->bump_sidebar_items (self);
	}
}

static void
tuba_instance_account_gather_v2_instance_info_data_free (gpointer _data)
{
	TubaInstanceAccountGatherV2InstanceInfoData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->self);
	g_slice_free (TubaInstanceAccountGatherV2InstanceInfoData, _data_);
}

static void
tuba_instance_account_gather_v2_instance_info (TubaInstanceAccount* self,
                                               GAsyncReadyCallback _callback_,
                                               gpointer _user_data_)
{
	TubaInstanceAccountGatherV2InstanceInfoData* _data_;
	TubaInstanceAccount* _tmp0_;
	g_return_if_fail (self != NULL);
	_data_ = g_slice_new0 (TubaInstanceAccountGatherV2InstanceInfoData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, tuba_instance_account_gather_v2_instance_info_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	tuba_instance_account_gather_v2_instance_info_co (_data_);
}

static void
tuba_instance_account_gather_v2_instance_info_finish (TubaInstanceAccount* self,
                                                      GAsyncResult* _res_)
{
	TubaInstanceAccountGatherV2InstanceInfoData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), NULL);
}

static void
tuba_instance_account_gather_v2_instance_info_ready (GObject* source_object,
                                                     GAsyncResult* _res_,
                                                     gpointer _user_data_)
{
	TubaInstanceAccountGatherV2InstanceInfoData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	tuba_instance_account_gather_v2_instance_info_co (_data_);
}

static TubaInstanceAccountInstanceFeatures*
_tuba_instance_account_instance_features_dup (TubaInstanceAccountInstanceFeatures* self)
{
	TubaInstanceAccountInstanceFeatures* dup;
	dup = g_new0 (TubaInstanceAccountInstanceFeatures, 1);
	memcpy (dup, self, sizeof (TubaInstanceAccountInstanceFeatures));
	return dup;
}

static gpointer
__tuba_instance_account_instance_features_dup0 (gpointer self)
{
	return self ? _tuba_instance_account_instance_features_dup (self) : NULL;
}

static gboolean
tuba_instance_account_gather_v2_instance_info_co (TubaInstanceAccountGatherV2InstanceInfoData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = _g_object_ref0 (_data_->self);
	_data_->_tmp1_ = NULL;
	_data_->_tmp1_ = tuba_request_v2_new ("/api/v2/instance", TUBA_REQUEST_V2_METHOD_GET);
	tuba_request_v2_set_account (_data_->_tmp1_, _data_->_tmp0_);
	_g_object_unref0 (_data_->_tmp0_);
	_data_->req = _data_->_tmp1_;
	{
		_data_->_tmp2_ = _data_->req;
		_data_->_state_ = 1;
		tuba_request_v2_exec (_data_->_tmp2_, tuba_instance_account_gather_v2_instance_info_ready, _data_);
		return FALSE;
		_state_1:
		_data_->_tmp3_ = tuba_request_v2_exec_finish (_data_->_tmp2_, _data_->_res_, NULL, &_data_->_inner_error0_);
		_data_->in_stream = _data_->_tmp3_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
		_data_->_tmp4_ = _data_->in_stream;
		_data_->_state_ = 2;
		tuba_network_get_parser_from_inputstream_async (_data_->_tmp4_, NULL, tuba_instance_account_gather_v2_instance_info_ready, _data_);
		return FALSE;
		_state_2:
		_data_->_tmp5_ = tuba_network_get_parser_from_inputstream_finish (_data_->_res_, &_data_->_inner_error0_);
		_data_->parser = _data_->_tmp5_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			_g_object_unref0 (_data_->in_stream);
			goto __catch0_g_error;
		}
		_data_->_tmp6_ = tuba_network;
		_data_->_tmp7_ = _data_->parser;
		_data_->_tmp8_ = tuba_network_parse_node (_data_->_tmp6_, _data_->_tmp7_);
		_data_->node = _data_->_tmp8_;
		_data_->_tmp9_ = _data_->node;
		if (_data_->_tmp9_ == NULL) {
			__vala_JsonNode_free0 (_data_->node);
			_g_object_unref0 (_data_->parser);
			_g_object_unref0 (_data_->in_stream);
			_g_object_unref0 (_data_->req);
			g_task_return_pointer (_data_->_async_result, _data_, NULL);
			if (_data_->_state_ != 0) {
				while (!g_task_get_completed (_data_->_async_result)) {
					g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
				}
			}
			g_object_unref (_data_->_async_result);
			return FALSE;
		}
		_data_->new_flags = NULL;
		_data_->_tmp10_ = _data_->node;
		_data_->_tmp11_ = tuba_api_instance_v2_from (_data_->_tmp10_, &_data_->_inner_error0_);
		_data_->instance_v2 = _data_->_tmp11_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			_g_free0 (_data_->new_flags);
			__vala_JsonNode_free0 (_data_->node);
			_g_object_unref0 (_data_->parser);
			_g_object_unref0 (_data_->in_stream);
			goto __catch0_g_error;
		}
		_data_->_tmp12_ = _data_->instance_v2;
		if (_data_->_tmp12_ != NULL) {
			_data_->_tmp13_ = _data_->self->priv->_tuba_instance_features;
			_data_->_tmp14_ = __tuba_instance_account_instance_features_dup0 (&_data_->_tmp13_);
			_g_free0 (_data_->new_flags);
			_data_->new_flags = _data_->_tmp14_;
			_data_->_tmp15_ = _data_->instance_v2;
			_data_->_tmp16_ = tuba_api_instance_v2_get_configuration (_data_->_tmp15_);
			_data_->_tmp17_ = _data_->_tmp16_;
			if (_data_->_tmp17_ != NULL) {
				_data_->_tmp18_ = _data_->instance_v2;
				_data_->_tmp19_ = tuba_api_instance_v2_get_configuration (_data_->_tmp18_);
				_data_->_tmp20_ = _data_->_tmp19_;
				_data_->_tmp21_ = tuba_api_instance_v2_configuration_get_translation (_data_->_tmp20_);
				_data_->_tmp22_ = _data_->_tmp21_;
				if (_data_->_tmp22_ != NULL) {
					_data_->_tmp23_ = _data_->self->priv->_instance_info;
					_data_->_tmp24_ = _data_->instance_v2;
					_data_->_tmp25_ = tuba_api_instance_v2_get_configuration (_data_->_tmp24_);
					_data_->_tmp26_ = _data_->_tmp25_;
					_data_->_tmp27_ = tuba_api_instance_v2_configuration_get_translation (_data_->_tmp26_);
					_data_->_tmp28_ = _data_->_tmp27_;
					_data_->_tmp29_ = tuba_api_instance_v2_configuration_translation_get_enabled (_data_->_tmp28_);
					_data_->_tmp30_ = _data_->_tmp29_;
					tuba_api_instance_set_tuba_can_translate (_data_->_tmp23_, _data_->_tmp30_);
				}
				_data_->_tmp31_ = _data_->instance_v2;
				_data_->_tmp32_ = tuba_api_instance_v2_get_configuration (_data_->_tmp31_);
				_data_->_tmp33_ = _data_->_tmp32_;
				_data_->_tmp34_ = tuba_api_instance_v2_configuration_get_media_attachments (_data_->_tmp33_);
				_data_->_tmp35_ = _data_->_tmp34_;
				if (_data_->_tmp35_ != NULL) {
					_data_->_tmp36_ = _data_->self->priv->_instance_info;
					_data_->_tmp37_ = _data_->instance_v2;
					_data_->_tmp38_ = tuba_api_instance_v2_get_configuration (_data_->_tmp37_);
					_data_->_tmp39_ = _data_->_tmp38_;
					_data_->_tmp40_ = tuba_api_instance_v2_configuration_get_media_attachments (_data_->_tmp39_);
					_data_->_tmp41_ = _data_->_tmp40_;
					_data_->_tmp42_ = tuba_api_instance_v2_configuration_media_attachments_get_description_limit (_data_->_tmp41_);
					_data_->_tmp43_ = _data_->_tmp42_;
					tuba_api_instance_set_tuba_max_alt_chars (_data_->_tmp36_, _data_->_tmp43_);
				}
				_data_->_tmp44_ = _data_->instance_v2;
				_data_->_tmp45_ = tuba_api_instance_v2_get_configuration (_data_->_tmp44_);
				_data_->_tmp46_ = _data_->_tmp45_;
				_data_->_tmp47_ = tuba_api_instance_v2_configuration_get_accounts (_data_->_tmp46_);
				_data_->_tmp48_ = _data_->_tmp47_;
				if (_data_->_tmp48_ != NULL) {
					_data_->_tmp49_ = _data_->self->priv->_instance_info;
					_data_->_tmp50_ = _data_->instance_v2;
					_data_->_tmp51_ = tuba_api_instance_v2_get_configuration (_data_->_tmp50_);
					_data_->_tmp52_ = _data_->_tmp51_;
					_data_->_tmp53_ = tuba_api_instance_v2_configuration_get_accounts (_data_->_tmp52_);
					_data_->_tmp54_ = _data_->_tmp53_;
					tuba_api_instance_set_tuba_limits (_data_->_tmp49_, _data_->_tmp54_);
				}
				_data_->_tmp56_ = _data_->self->priv->_instance_info;
				_data_->_tmp57_ = tuba_api_instance_get_tuba_can_translate (_data_->_tmp56_);
				_data_->_tmp58_ = _data_->_tmp57_;
				if (_data_->_tmp58_) {
					_data_->_tmp59_ = _data_->new_flags;
					_data_->_tmp55_ = (*_data_->_tmp59_) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_TRANSLATION;
				} else {
					_data_->_tmp60_ = _data_->new_flags;
					_data_->_tmp55_ = (*_data_->_tmp60_) & (~TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_TRANSLATION);
				}
				_data_->_tmp61_ = __tuba_instance_account_instance_features_dup0 (&_data_->_tmp55_);
				_g_free0 (_data_->new_flags);
				_data_->new_flags = _data_->_tmp61_;
			}
			_data_->_tmp63_ = _data_->instance_v2;
			_data_->_tmp64_ = tuba_api_instance_v2_get_api_versions (_data_->_tmp63_);
			_data_->_tmp65_ = _data_->_tmp64_;
			if (_data_->_tmp65_ != NULL) {
				_data_->_tmp66_ = _data_->instance_v2;
				_data_->_tmp67_ = tuba_api_instance_v2_get_api_versions (_data_->_tmp66_);
				_data_->_tmp68_ = _data_->_tmp67_;
				_data_->_tmp69_ = tuba_api_instance_v2_api_versions_get_mastodon (_data_->_tmp68_);
				_data_->_tmp70_ = _data_->_tmp69_;
				_data_->_tmp62_ = ((gint) _data_->_tmp70_) > 0;
			} else {
				_data_->_tmp62_ = FALSE;
			}
			if (_data_->_tmp62_) {
				_data_->_tmp71_ = _data_->self->priv->_tuba_api_versions;
				_data_->_tmp72_ = _data_->instance_v2;
				_data_->_tmp73_ = tuba_api_instance_v2_get_api_versions (_data_->_tmp72_);
				_data_->_tmp74_ = _data_->_tmp73_;
				if (!tuba_api_instance_v2_api_versions_tuba_same (_data_->_tmp71_, _data_->_tmp74_)) {
					_data_->_tmp75_ = _data_->instance_v2;
					_data_->_tmp76_ = tuba_api_instance_v2_get_api_versions (_data_->_tmp75_);
					_data_->_tmp77_ = _data_->_tmp76_;
					tuba_instance_account_set_tuba_api_versions (_data_->self, _data_->_tmp77_);
					_data_->_tmp78_ = tuba_accounts;
					tuba_account_store_update_account (_data_->_tmp78_, _data_->self, &_data_->_inner_error0_);
					if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
						_g_object_unref0 (_data_->instance_v2);
						_g_free0 (_data_->new_flags);
						__vala_JsonNode_free0 (_data_->node);
						_g_object_unref0 (_data_->parser);
						_g_object_unref0 (_data_->in_stream);
						goto __catch0_g_error;
					}
				}
				tuba_instance_account_set_tuba_probably_has_notification_filters (_data_->self, TRUE);
				_data_->_tmp79_ = _data_->self->priv->_tuba_api_versions;
				_data_->_tmp80_ = tuba_api_instance_v2_api_versions_get_mastodon (_data_->_tmp79_);
				_data_->_tmp81_ = _data_->_tmp80_;
				if (((gint) _data_->_tmp81_) > 1) {
					tuba_instance_account_gather_annual_report (_data_->self, NULL, NULL);
					_data_->_tmp82_ = _data_->new_flags;
					_data_->_tmp83_ = (*_data_->_tmp82_) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GROUP_NOTIFICATIONS;
					_data_->_tmp84_ = __tuba_instance_account_instance_features_dup0 (&_data_->_tmp83_);
					_g_free0 (_data_->new_flags);
					_data_->new_flags = _data_->_tmp84_;
				}
				_data_->_tmp85_ = _data_->self->priv->_tuba_api_versions;
				_data_->_tmp86_ = tuba_api_instance_v2_api_versions_get_mastodon (_data_->_tmp85_);
				_data_->_tmp87_ = _data_->_tmp86_;
				if (((gint) _data_->_tmp87_) > 5) {
					_data_->_tmp88_ = _data_->new_flags;
					_data_->_tmp89_ = (*_data_->_tmp88_) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ENDORSE_USERS;
					_data_->_tmp90_ = __tuba_instance_account_instance_features_dup0 (&_data_->_tmp89_);
					_g_free0 (_data_->new_flags);
					_data_->new_flags = _data_->_tmp90_;
				}
				_data_->_tmp91_ = _data_->self->priv->_tuba_api_versions;
				_data_->_tmp92_ = tuba_api_instance_v2_api_versions_get_mastodon (_data_->_tmp91_);
				_data_->_tmp93_ = _data_->_tmp92_;
				if (((gint) _data_->_tmp93_) >= 7) {
					_data_->_tmp94_ = _data_->new_flags;
					_data_->_tmp95_ = (*_data_->_tmp94_) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_QUOTE;
					_data_->_tmp96_ = __tuba_instance_account_instance_features_dup0 (&_data_->_tmp95_);
					_g_free0 (_data_->new_flags);
					_data_->new_flags = _data_->_tmp96_;
				}
				_data_->_tmp97_ = _data_->self->priv->_tuba_api_versions;
				_data_->_tmp98_ = tuba_api_instance_v2_api_versions_get_chuckya (_data_->_tmp97_);
				_data_->_tmp99_ = _data_->_tmp98_;
				if (((gint) _data_->_tmp99_) > 0) {
					_data_->_tmp100_ = _data_->new_flags;
					_data_->_tmp101_ = (*_data_->_tmp100_) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_EMOJI_REACTIONS;
					_data_->_tmp102_ = __tuba_instance_account_instance_features_dup0 (&_data_->_tmp101_);
					_g_free0 (_data_->new_flags);
					_data_->new_flags = _data_->_tmp102_;
				}
				_data_->_tmp103_ = _data_->new_flags;
				_data_->_tmp104_ = (*_data_->_tmp103_) | (TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_FEATURE_TAGS | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_MUTUALS);
				_data_->_tmp105_ = __tuba_instance_account_instance_features_dup0 (&_data_->_tmp104_);
				_g_free0 (_data_->new_flags);
				_data_->new_flags = _data_->_tmp105_;
				_data_->_tmp106_ = _data_->self->priv->_instance_info;
				_data_->_tmp107_ = tuba_api_instance_get_supports_bubble (_data_->_tmp106_);
				_data_->_tmp108_ = _data_->_tmp107_;
				if (_data_->_tmp108_) {
					_data_->_tmp109_ = _data_->new_flags;
					_data_->_tmp110_ = (*_data_->_tmp109_) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_BUBBLE;
					_data_->_tmp111_ = __tuba_instance_account_instance_features_dup0 (&_data_->_tmp110_);
					_g_free0 (_data_->new_flags);
					_data_->new_flags = _data_->_tmp111_;
				}
			}
		}
		_data_->_tmp112_ = _data_->new_flags;
		if (_data_->_tmp112_ != NULL) {
			_data_->_tmp113_ = _data_->new_flags;
			tuba_instance_account_tuba_instance_features_update_and_save (_data_->self, *_data_->_tmp113_);
		}
		tuba_instance_account_bump_sidebar_items (_data_->self);
		_g_object_unref0 (_data_->instance_v2);
		_g_free0 (_data_->new_flags);
		__vala_JsonNode_free0 (_data_->node);
		_g_object_unref0 (_data_->parser);
		_g_object_unref0 (_data_->in_stream);
	}
	goto __finally0;
	__catch0_g_error:
	{
		_data_->e = _data_->_inner_error0_;
		_data_->_inner_error0_ = NULL;
		_data_->_tmp114_ = _data_->e;
		_data_->_tmp115_ = g_strdup_printf ("%i", _data_->_tmp114_->code);
		_data_->_tmp116_ = _data_->_tmp115_;
		_data_->_tmp117_ = _data_->e;
		_data_->_tmp118_ = _data_->_tmp117_->message;
		_data_->_tmp119_ = string_to_string (_data_->_tmp118_);
		_data_->_tmp120_ = g_strconcat ("Couldn't fetch instance v2: ", _data_->_tmp116_, " ", _data_->_tmp119_, NULL);
		_data_->_tmp121_ = _data_->_tmp120_;
		g_warning ("InstanceAccount.vala:803: %s", _data_->_tmp121_);
		_g_free0 (_data_->_tmp121_);
		_g_free0 (_data_->_tmp116_);
		_g_error_free0 (_data_->e);
	}
	__finally0:
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		_g_object_unref0 (_data_->req);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error0_->message, g_quark_to_string (_data_->_inner_error0_->domain), _data_->_inner_error0_->code);
		g_clear_error (&_data_->_inner_error0_);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_g_object_unref0 (_data_->req);
	g_task_return_pointer (_data_->_async_result, _data_, NULL);
	if (_data_->_state_ != 0) {
		while (!g_task_get_completed (_data_->_async_result)) {
			g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
		}
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}

static void
tuba_instance_account_gather_annual_report_data_free (gpointer _data)
{
	TubaInstanceAccountGatherAnnualReportData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->self);
	g_slice_free (TubaInstanceAccountGatherAnnualReportData, _data_);
}

static void
tuba_instance_account_gather_annual_report (TubaInstanceAccount* self,
                                            GAsyncReadyCallback _callback_,
                                            gpointer _user_data_)
{
	TubaInstanceAccountGatherAnnualReportData* _data_;
	TubaInstanceAccount* _tmp0_;
	g_return_if_fail (self != NULL);
	_data_ = g_slice_new0 (TubaInstanceAccountGatherAnnualReportData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, tuba_instance_account_gather_annual_report_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	tuba_instance_account_gather_annual_report_co (_data_);
}

static void
tuba_instance_account_gather_annual_report_finish (TubaInstanceAccount* self,
                                                   GAsyncResult* _res_)
{
	TubaInstanceAccountGatherAnnualReportData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), NULL);
}

static void
tuba_instance_account_gather_annual_report_ready (GObject* source_object,
                                                  GAsyncResult* _res_,
                                                  gpointer _user_data_)
{
	TubaInstanceAccountGatherAnnualReportData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	tuba_instance_account_gather_annual_report_co (_data_);
}

static gboolean
tuba_instance_account_gather_annual_report_co (TubaInstanceAccountGatherAnnualReportData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = g_time_zone_new_local ();
	_data_->_tmp1_ = _data_->_tmp0_;
	_data_->_tmp2_ = g_date_time_new_now (_data_->_tmp1_);
	_data_->_tmp3_ = _data_->_tmp2_;
	_g_time_zone_unref0 (_data_->_tmp1_);
	_data_->now = _data_->_tmp3_;
	_data_->year = 0;
	_data_->_tmp4_ = _data_->now;
	switch (g_date_time_get_month (_data_->_tmp4_)) {
		case 12:
		{
			_data_->_tmp5_ = _data_->now;
			_data_->year = g_date_time_get_year (_data_->_tmp5_);
			break;
		}
		case 1:
		{
			_data_->_tmp6_ = _data_->now;
			_data_->year = g_date_time_get_year (_data_->_tmp6_) - 1;
			break;
		}
		default:
		{
			_g_date_time_unref0 (_data_->now);
			g_task_return_pointer (_data_->_async_result, _data_, NULL);
			if (_data_->_state_ != 0) {
				while (!g_task_get_completed (_data_->_async_result)) {
					g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
				}
			}
			g_object_unref (_data_->_async_result);
			return FALSE;
		}
	}
	_data_->_tmp7_ = g_strdup_printf ("%i", _data_->year);
	_data_->_tmp8_ = _data_->_tmp7_;
	_data_->_tmp9_ = g_strconcat ("/api/v1/annual_reports/", _data_->_tmp8_, NULL);
	_data_->_tmp10_ = _data_->_tmp9_;
	_data_->_tmp11_ = _g_object_ref0 (_data_->self);
	_data_->_tmp12_ = NULL;
	_data_->_tmp12_ = tuba_request_v2_new (_data_->_tmp10_, TUBA_REQUEST_V2_METHOD_GET);
	tuba_request_v2_set_account (_data_->_tmp12_, _data_->_tmp11_);
	_g_object_unref0 (_data_->_tmp11_);
	_data_->_tmp13_ = _data_->_tmp12_;
	_g_free0 (_data_->_tmp10_);
	_g_free0 (_data_->_tmp8_);
	_data_->req = _data_->_tmp13_;
	{
		_data_->_tmp14_ = _data_->req;
		_data_->_state_ = 1;
		tuba_request_v2_exec (_data_->_tmp14_, tuba_instance_account_gather_annual_report_ready, _data_);
		return FALSE;
		_state_1:
		_data_->_tmp15_ = tuba_request_v2_exec_finish (_data_->_tmp14_, _data_->_res_, NULL, &_data_->_inner_error0_);
		_data_->in_stream = _data_->_tmp15_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
		_data_->_tmp16_ = _data_->in_stream;
		_data_->_state_ = 2;
		tuba_network_get_parser_from_inputstream_async (_data_->_tmp16_, NULL, tuba_instance_account_gather_annual_report_ready, _data_);
		return FALSE;
		_state_2:
		_data_->_tmp17_ = tuba_network_get_parser_from_inputstream_finish (_data_->_res_, &_data_->_inner_error0_);
		_data_->parser = _data_->_tmp17_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			_g_object_unref0 (_data_->in_stream);
			goto __catch0_g_error;
		}
		_data_->_tmp18_ = tuba_network;
		_data_->_tmp19_ = _data_->parser;
		_data_->_tmp20_ = tuba_network_parse_node (_data_->_tmp18_, _data_->_tmp19_);
		_data_->node = _data_->_tmp20_;
		_data_->_tmp22_ = _data_->node;
		_data_->_tmp23_ = tuba_api_annual_reports_from (_data_->_tmp22_, &_data_->_inner_error0_);
		_data_->_tmp21_ = _data_->_tmp23_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			__vala_JsonNode_free0 (_data_->node);
			_g_object_unref0 (_data_->parser);
			_g_object_unref0 (_data_->in_stream);
			goto __catch0_g_error;
		}
		_data_->_tmp24_ = _data_->_tmp21_;
		_data_->_tmp21_ = NULL;
		_g_object_unref0 (_data_->self->priv->annual_report);
		_data_->self->priv->annual_report = _data_->_tmp24_;
		_data_->_tmp25_ = _data_->self->priv->annual_report;
		_data_->_tmp26_ = tuba_api_annual_reports_get_annual_reports (_data_->_tmp25_);
		_data_->_tmp27_ = _data_->_tmp26_;
		_data_->_tmp28_ = gee_abstract_collection_get_size ((GeeAbstractCollection*) _data_->_tmp27_);
		_data_->_tmp29_ = _data_->_tmp28_;
		if (_data_->_tmp29_ > 0) {
			tuba_instance_account_set_tuba_last_fediwrapped_year (_data_->self, _data_->year);
		}
		_g_object_unref0 (_data_->_tmp21_);
		__vala_JsonNode_free0 (_data_->node);
		_g_object_unref0 (_data_->parser);
		_g_object_unref0 (_data_->in_stream);
	}
	goto __finally0;
	__catch0_g_error:
	{
		_data_->e = _data_->_inner_error0_;
		_data_->_inner_error0_ = NULL;
		_data_->_tmp30_ = _data_->e;
		_data_->_tmp31_ = g_strdup_printf ("%i", _data_->_tmp30_->code);
		_data_->_tmp32_ = _data_->_tmp31_;
		_data_->_tmp33_ = _data_->e;
		_data_->_tmp34_ = _data_->_tmp33_->message;
		_data_->_tmp35_ = string_to_string (_data_->_tmp34_);
		_data_->_tmp36_ = g_strconcat ("Couldn't fetch annual reports: ", _data_->_tmp32_, " ", _data_->_tmp35_, NULL);
		_data_->_tmp37_ = _data_->_tmp36_;
		g_debug ("InstanceAccount.vala:832: %s", _data_->_tmp37_);
		_g_free0 (_data_->_tmp37_);
		_g_free0 (_data_->_tmp32_);
		_g_error_free0 (_data_->e);
	}
	__finally0:
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		_g_object_unref0 (_data_->req);
		_g_date_time_unref0 (_data_->now);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error0_->message, g_quark_to_string (_data_->_inner_error0_->domain), _data_->_inner_error0_->code);
		g_clear_error (&_data_->_inner_error0_);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_g_object_unref0 (_data_->req);
	_g_date_time_unref0 (_data_->now);
	g_task_return_pointer (_data_->_async_result, _data_, NULL);
	if (_data_->_state_ != 0) {
		while (!g_task_get_completed (_data_->_async_result)) {
			g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
		}
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}

void
tuba_instance_account_open_latest_wrapped (TubaInstanceAccount* self)
{
	gboolean _tmp0_ = FALSE;
	gint _tmp1_;
	TubaAPIAnnualReports* _tmp3_;
	gint _tmp4_;
	g_return_if_fail (self != NULL);
	_tmp1_ = self->priv->_tuba_last_fediwrapped_year;
	if (_tmp1_ == 0) {
		_tmp0_ = TRUE;
	} else {
		TubaAPIAnnualReports* _tmp2_;
		_tmp2_ = self->priv->annual_report;
		_tmp0_ = _tmp2_ == NULL;
	}
	if (_tmp0_) {
		return;
	}
	_tmp3_ = self->priv->annual_report;
	_tmp4_ = self->priv->_tuba_last_fediwrapped_year;
	tuba_api_annual_reports_open (_tmp3_, _tmp4_);
	tuba_instance_account_set_tuba_last_fediwrapped_year (self, 0);
	_g_object_unref0 (self->priv->annual_report);
	self->priv->annual_report = NULL;
}

static void
tuba_instance_account_gather_instance_custom_emojis_data_free (gpointer _data)
{
	TubaInstanceAccountGatherInstanceCustomEmojisData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->self);
	g_slice_free (TubaInstanceAccountGatherInstanceCustomEmojisData, _data_);
}

void
tuba_instance_account_gather_instance_custom_emojis (TubaInstanceAccount* self,
                                                     GAsyncReadyCallback _callback_,
                                                     gpointer _user_data_)
{
	TubaInstanceAccountGatherInstanceCustomEmojisData* _data_;
	TubaInstanceAccount* _tmp0_;
	g_return_if_fail (self != NULL);
	_data_ = g_slice_new0 (TubaInstanceAccountGatherInstanceCustomEmojisData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, tuba_instance_account_gather_instance_custom_emojis_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	tuba_instance_account_gather_instance_custom_emojis_co (_data_);
}

void
tuba_instance_account_gather_instance_custom_emojis_finish (TubaInstanceAccount* self,
                                                            GAsyncResult* _res_)
{
	TubaInstanceAccountGatherInstanceCustomEmojisData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), NULL);
}

static void
tuba_instance_account_gather_instance_custom_emojis_ready (GObject* source_object,
                                                           GAsyncResult* _res_,
                                                           gpointer _user_data_)
{
	TubaInstanceAccountGatherInstanceCustomEmojisData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	tuba_instance_account_gather_instance_custom_emojis_co (_data_);
}

static gboolean
tuba_instance_account_gather_instance_custom_emojis_co (TubaInstanceAccountGatherInstanceCustomEmojisData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = _data_->self->priv->_instance_emojis;
	if (_data_->_tmp0_ != NULL) {
		g_task_return_pointer (_data_->_async_result, _data_, NULL);
		if (_data_->_state_ != 0) {
			while (!g_task_get_completed (_data_->_async_result)) {
				g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
			}
		}
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp1_ = _g_object_ref0 (_data_->self);
	_data_->_tmp2_ = NULL;
	_data_->_tmp2_ = tuba_request_v2_new ("/api/v1/custom_emojis", TUBA_REQUEST_V2_METHOD_GET);
	tuba_request_v2_set_account (_data_->_tmp2_, _data_->_tmp1_);
	_g_object_unref0 (_data_->_tmp1_);
	_data_->req = _data_->_tmp2_;
	{
		_data_->_tmp3_ = _data_->req;
		_data_->_state_ = 1;
		tuba_request_v2_exec (_data_->_tmp3_, tuba_instance_account_gather_instance_custom_emojis_ready, _data_);
		return FALSE;
		_state_1:
		_data_->_tmp4_ = tuba_request_v2_exec_finish (_data_->_tmp3_, _data_->_res_, NULL, &_data_->_inner_error0_);
		_data_->in_stream = _data_->_tmp4_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
		_data_->_tmp5_ = _data_->in_stream;
		_data_->_state_ = 2;
		tuba_network_get_parser_from_inputstream_async (_data_->_tmp5_, NULL, tuba_instance_account_gather_instance_custom_emojis_ready, _data_);
		return FALSE;
		_state_2:
		_data_->_tmp6_ = tuba_network_get_parser_from_inputstream_finish (_data_->_res_, &_data_->_inner_error0_);
		_data_->parser = _data_->_tmp6_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			_g_object_unref0 (_data_->in_stream);
			goto __catch0_g_error;
		}
		_data_->_tmp7_ = tuba_network;
		_data_->_tmp8_ = _data_->parser;
		_data_->_tmp9_ = tuba_network_parse_node (_data_->_tmp7_, _data_->_tmp8_);
		_data_->node = _data_->_tmp9_;
		_data_->_tmp10_ = _data_->node;
		if (_data_->_tmp10_ == NULL) {
			__vala_JsonNode_free0 (_data_->node);
			_g_object_unref0 (_data_->parser);
			_g_object_unref0 (_data_->in_stream);
			_g_object_unref0 (_data_->req);
			g_task_return_pointer (_data_->_async_result, _data_, NULL);
			if (_data_->_state_ != 0) {
				while (!g_task_get_completed (_data_->_async_result)) {
					g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
				}
			}
			g_object_unref (_data_->_async_result);
			return FALSE;
		}
		_data_->_tmp11_ = _data_->node;
		memset (&_data_->_tmp12_, 0, sizeof (GValue));
		tuba_entity_des_list (&_data_->_tmp12_, _data_->_tmp11_, TUBA_API_TYPE_EMOJI);
		G_IS_VALUE (&_data_->res_emojis) ? (g_value_unset (&_data_->res_emojis), NULL) : NULL;
		_data_->res_emojis = _data_->_tmp12_;
		_data_->_tmp13_ = _data_->res_emojis;
		tuba_instance_account_set_instance_emojis (_data_->self, g_value_get_object (&_data_->_tmp13_));
		G_IS_VALUE (&_data_->res_emojis) ? (g_value_unset (&_data_->res_emojis), NULL) : NULL;
		__vala_JsonNode_free0 (_data_->node);
		_g_object_unref0 (_data_->parser);
		_g_object_unref0 (_data_->in_stream);
	}
	goto __finally0;
	__catch0_g_error:
	{
		_data_->e = _data_->_inner_error0_;
		_data_->_inner_error0_ = NULL;
		_data_->_tmp14_ = _data_->e;
		_data_->_tmp15_ = g_strdup_printf ("%i", _data_->_tmp14_->code);
		_data_->_tmp16_ = _data_->_tmp15_;
		_data_->_tmp17_ = _data_->e;
		_data_->_tmp18_ = _data_->_tmp17_->message;
		_data_->_tmp19_ = string_to_string (_data_->_tmp18_);
		_data_->_tmp20_ = g_strconcat ("Couldn't fetch custom emojis: ", _data_->_tmp16_, " ", _data_->_tmp19_, NULL);
		_data_->_tmp21_ = _data_->_tmp20_;
		g_warning ("InstanceAccount.vala:857: %s", _data_->_tmp21_);
		_g_free0 (_data_->_tmp21_);
		_g_free0 (_data_->_tmp16_);
		_g_error_free0 (_data_->e);
	}
	__finally0:
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		_g_object_unref0 (_data_->req);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error0_->message, g_quark_to_string (_data_->_inner_error0_->domain), _data_->_inner_error0_->code);
		g_clear_error (&_data_->_inner_error0_);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_g_object_unref0 (_data_->req);
	g_task_return_pointer (_data_->_async_result, _data_, NULL);
	if (_data_->_state_ != 0) {
		while (!g_task_get_completed (_data_->_async_result)) {
			g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
		}
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}

static void
____lambda41_ (TubaDialogsMainWindow* win,
               GObject* tag_obj)
{
	gchar* tag_str = NULL;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	gchar* _tmp2_;
	const gchar* _tmp3_;
	const gchar* _tmp4_;
	gchar* _tmp5_;
	gchar* _tmp6_;
	TubaViewsHashtag* _tmp7_;
	TubaViewsHashtag* _tmp8_;
	TubaViewsBase* _tmp9_;
	TubaViewsBase* _tmp10_;
	TubaViewsBase* _tmp11_;
	TubaViewsBase* _tmp12_;
	guint egg_hash = 0U;
	GHashFunc _tmp13_;
	const gchar* _tmp14_;
	gchar* _tmp15_;
	gchar* _tmp16_;
	guint _tmp17_;
	g_return_if_fail (win != NULL);
	_tmp0_ = gtk_string_object_get_string (G_TYPE_CHECK_INSTANCE_CAST (tag_obj, gtk_string_object_get_type (), GtkStringObject));
	_tmp1_ = _tmp0_;
	_tmp2_ = g_strdup (_tmp1_);
	tag_str = _tmp2_;
	_tmp3_ = tag_str;
	_tmp4_ = tag_str;
	_tmp5_ = g_uri_escape_string (_tmp4_, NULL, TRUE);
	_tmp6_ = _tmp5_;
	_tmp7_ = tuba_views_hashtag_new (_tmp3_, NULL, _tmp6_, NULL);
	g_object_ref_sink (_tmp7_);
	_tmp8_ = _tmp7_;
	_tmp9_ = tuba_instance_account_set_as_sidebar_item ((TubaViewsBase*) _tmp8_);
	_tmp10_ = _tmp9_;
	_tmp11_ = tuba_dialogs_main_window_open_view (win, _tmp10_);
	_tmp12_ = _tmp11_;
	_g_object_unref0 (_tmp12_);
	_g_object_unref0 (_tmp10_);
	_g_object_unref0 (_tmp8_);
	_g_free0 (_tmp6_);
	_tmp13_ = g_str_hash;
	_tmp14_ = tag_str;
	_tmp15_ = g_utf8_strdown (_tmp14_, (gssize) -1);
	_tmp16_ = _tmp15_;
	_tmp17_ = _tmp13_ (_tmp16_);
	_g_free0 (_tmp16_);
	egg_hash = _tmp17_;
	if (((gint64) egg_hash) == 3906476199LL) {
		TubaApplication* _tmp18_;
		_tmp18_ = tuba_app;
		tuba_application_load_egg (_tmp18_, "7");
	} else {
		if (egg_hash == ((guint) 2090371718)) {
			TubaApplication* _tmp19_;
			_tmp19_ = tuba_app;
			tuba_application_load_egg (_tmp19_, "6");
		}
	}
	_g_free0 (tag_str);
}

static void
_____lambda41__tuba_place_open_func (TubaDialogsMainWindow* window,
                                     GObject* extra)
{
	____lambda41_ (window, extra);
}

static void
_vala_array_add50 (TubaPlace** * array,
                   gint* length,
                   gint* size,
                   TubaPlace* value)
{
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (TubaPlace*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}

gboolean
tuba_instance_account_gather_fav_tags (TubaInstanceAccount* self)
{
	TubaSettings* _tmp0_;
	gchar** _tmp1_;
	gint _tmp1__length1;
	gint _tmp2_ = 0;
	gchar** _tmp3_;
	gint _tmp3__length1;
	TubaPlace** fav_tags = NULL;
	TubaPlace** _tmp5_;
	gint fav_tags_length1;
	gint _fav_tags_size_;
	TubaSettings* _tmp6_;
	gchar** _tmp7_;
	gint _tmp7__length1;
	gint _tmp8_ = 0;
	gchar** _tmp9_;
	gint _tmp9__length1;
	TubaPlace** _tmp17_;
	gint _tmp17__length1;
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	_tmp0_ = tuba_settings;
	_tmp1_ = tuba_settings_get_favorite_tags_ids (_tmp0_, &_tmp2_);
	_tmp1__length1 = _tmp2_;
	_tmp3_ = _tmp1_;
	_tmp3__length1 = _tmp1__length1;
	if (_tmp3__length1 == 0) {
		GListStore* _tmp4_;
		_tmp4_ = self->tags_places;
		tuba_instance_account_register_extra (self, _tmp4_, NULL, (gint) 0);
		result = G_SOURCE_REMOVE;
		return result;
	}
	_tmp5_ = g_new0 (TubaPlace*, 0 + 1);
	fav_tags = _tmp5_;
	fav_tags_length1 = 0;
	_fav_tags_size_ = fav_tags_length1;
	_tmp6_ = tuba_settings;
	_tmp7_ = tuba_settings_get_favorite_tags_ids (_tmp6_, &_tmp8_);
	_tmp7__length1 = _tmp8_;
	_tmp9_ = _tmp7_;
	_tmp9__length1 = _tmp7__length1;
	{
		gchar** tag_collection = NULL;
		gint tag_collection_length1 = 0;
		gint _tag_collection_size_ = 0;
		gint tag_it = 0;
		tag_collection = _tmp9_;
		tag_collection_length1 = _tmp9__length1;
		for (tag_it = 0; tag_it < tag_collection_length1; tag_it = tag_it + 1) {
			gchar* _tmp10_;
			gchar* tag = NULL;
			_tmp10_ = g_strdup (tag_collection[tag_it]);
			tag = _tmp10_;
			{
				gchar* _tmp11_;
				const gchar* _tmp12_;
				gchar* _tmp13_;
				const gchar* _tmp14_;
				GtkStringObject* _tmp15_;
				TubaPlace* _tmp16_ = NULL;
				_tmp11_ = g_strdup ("tuba-hashtag-symbolic");
				_tmp12_ = tag;
				_tmp13_ = g_strdup (_tmp12_);
				_tmp14_ = tag;
				_tmp15_ = gtk_string_object_new (_tmp14_);
				_tmp16_ = tuba_place_new ();
				tuba_place_set_icon (_tmp16_, _tmp11_);
				_g_free0 (_tmp11_);
				tuba_place_set_title (_tmp16_, _tmp13_);
				_g_free0 (_tmp13_);
				tuba_place_set_extra_data (_tmp16_, (GObject*) _tmp15_);
				_g_object_unref0 (_tmp15_);
				tuba_place_set_open_func (_tmp16_, _____lambda41__tuba_place_open_func);
				_vala_array_add50 (&fav_tags, &fav_tags_length1, &_fav_tags_size_, _tmp16_);
				_g_free0 (tag);
			}
		}
	}
	_tmp17_ = fav_tags;
	_tmp17__length1 = fav_tags_length1;
	if (_tmp17__length1 > 0) {
		GListStore* _tmp18_;
		TubaPlace** _tmp19_;
		gint _tmp19__length1;
		_tmp18_ = self->tags_places;
		_tmp19_ = fav_tags;
		_tmp19__length1 = fav_tags_length1;
		tuba_instance_account_register_extra (self, _tmp18_, _tmp19_, (gint) _tmp19__length1);
	}
	result = G_SOURCE_REMOVE;
	fav_tags = (_vala_array_free (fav_tags, fav_tags_length1, (GDestroyNotify) g_object_unref), NULL);
	return result;
}

static void
tuba_instance_account_gather_fav_lists_data_free (gpointer _data)
{
	TubaInstanceAccountGatherFavListsData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->self);
	g_slice_free (TubaInstanceAccountGatherFavListsData, _data_);
}

void
tuba_instance_account_gather_fav_lists (TubaInstanceAccount* self,
                                        GAsyncReadyCallback _callback_,
                                        gpointer _user_data_)
{
	TubaInstanceAccountGatherFavListsData* _data_;
	TubaInstanceAccount* _tmp0_;
	g_return_if_fail (self != NULL);
	_data_ = g_slice_new0 (TubaInstanceAccountGatherFavListsData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, tuba_instance_account_gather_fav_lists_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	tuba_instance_account_gather_fav_lists_co (_data_);
}

void
tuba_instance_account_gather_fav_lists_finish (TubaInstanceAccount* self,
                                               GAsyncResult* _res_)
{
	TubaInstanceAccountGatherFavListsData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), NULL);
}

static Block49Data*
block49_data_ref (Block49Data* _data49_)
{
	g_atomic_int_inc (&_data49_->_ref_count_);
	return _data49_;
}

static void
block49_data_unref (void * _userdata_)
{
	Block49Data* _data49_;
	_data49_ = (Block49Data*) _userdata_;
	if (g_atomic_int_dec_and_test (&_data49_->_ref_count_)) {
		TubaInstanceAccount* self;
		self = _data49_->self;
		_data49_->all_ids = (_vala_array_free (_data49_->all_ids, _data49_->all_ids_length1, (GDestroyNotify) g_free), NULL);
		_data49_->fav_lists = (_vala_array_free (_data49_->fav_lists, _data49_->fav_lists_length1, (GDestroyNotify) g_object_unref), NULL);
		_g_object_unref0 (self);
		g_slice_free (Block49Data, _data49_);
	}
}

static void
tuba_instance_account_gather_fav_lists_ready (GObject* source_object,
                                              GAsyncResult* _res_,
                                              gpointer _user_data_)
{
	TubaInstanceAccountGatherFavListsData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	tuba_instance_account_gather_fav_lists_co (_data_);
}

static void
___lambda157_ (TubaDialogsMainWindow* win,
               GObject* list)
{
	TubaViewsList* _tmp0_;
	TubaViewsList* _tmp1_;
	TubaViewsBase* _tmp2_;
	TubaViewsBase* _tmp3_;
	TubaViewsBase* _tmp4_;
	TubaViewsBase* _tmp5_;
	g_return_if_fail (win != NULL);
	_tmp0_ = tuba_views_list_new (G_TYPE_CHECK_INSTANCE_CAST (list, TUBA_API_TYPE_LIST, TubaAPIList));
	g_object_ref_sink (_tmp0_);
	_tmp1_ = _tmp0_;
	_tmp2_ = tuba_instance_account_set_as_sidebar_item ((TubaViewsBase*) _tmp1_);
	_tmp3_ = _tmp2_;
	_tmp4_ = tuba_dialogs_main_window_open_view (win, _tmp3_);
	_tmp5_ = _tmp4_;
	_g_object_unref0 (_tmp5_);
	_g_object_unref0 (_tmp3_);
	_g_object_unref0 (_tmp1_);
}

static void
____lambda157__tuba_place_open_func (TubaDialogsMainWindow* window,
                                     GObject* extra)
{
	___lambda157_ (window, extra);
}

static void
_vala_array_add51 (TubaPlace** * array,
                   gint* length,
                   gint* size,
                   TubaPlace* value)
{
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (TubaPlace*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}

static void
_vala_array_add52 (gchar** * array,
                   gint* length,
                   gint* size,
                   gchar* value)
{
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (gchar*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}

static void
___lambda156_ (Block49Data* _data49_,
               JsonNode* node,
               GError** error)
{
	TubaInstanceAccount* self;
	TubaAPIList* list = NULL;
	TubaAPIList* _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	TubaSettings* _tmp3_;
	gchar** _tmp4_;
	gint _tmp4__length1;
	gint _tmp5_ = 0;
	gchar** _tmp6_;
	gint _tmp6__length1;
	const gchar* _tmp13_;
	const gchar* _tmp14_;
	gchar* _tmp15_;
	GError* _inner_error0_ = NULL;
	self = _data49_->self;
	g_return_if_fail (node != NULL);
	_tmp0_ = tuba_api_list_from (node, &_inner_error0_);
	list = _tmp0_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return;
	}
	_tmp1_ = tuba_api_list_get_id (list);
	_tmp2_ = _tmp1_;
	_tmp3_ = tuba_settings;
	_tmp4_ = tuba_settings_get_favorite_lists_ids (_tmp3_, &_tmp5_);
	_tmp4__length1 = _tmp5_;
	_tmp6_ = _tmp4_;
	_tmp6__length1 = _tmp4__length1;
	if (_vala_string_array_contains (_tmp6_, _tmp6__length1, _tmp2_)) {
		gchar* _tmp7_;
		const gchar* _tmp8_;
		const gchar* _tmp9_;
		gchar* _tmp10_;
		GObject* _tmp11_;
		TubaPlace* _tmp12_ = NULL;
		_tmp7_ = g_strdup ("tuba-list-compact-symbolic");
		_tmp8_ = tuba_api_list_get_title (list);
		_tmp9_ = _tmp8_;
		_tmp10_ = g_strdup (_tmp9_);
		_tmp11_ = _g_object_ref0 ((GObject*) list);
		_tmp12_ = tuba_place_new ();
		tuba_place_set_icon (_tmp12_, _tmp7_);
		_g_free0 (_tmp7_);
		tuba_place_set_title (_tmp12_, _tmp10_);
		_g_free0 (_tmp10_);
		tuba_place_set_extra_data (_tmp12_, _tmp11_);
		_g_object_unref0 (_tmp11_);
		tuba_place_set_open_func (_tmp12_, ____lambda157__tuba_place_open_func);
		_vala_array_add51 (&_data49_->fav_lists, &_data49_->fav_lists_length1, &_data49_->_fav_lists_size_, _tmp12_);
	}
	_tmp13_ = tuba_api_list_get_id (list);
	_tmp14_ = _tmp13_;
	_tmp15_ = g_strdup (_tmp14_);
	_vala_array_add52 (&_data49_->all_ids, &_data49_->all_ids_length1, &_data49_->_all_ids_size_, _tmp15_);
	_g_object_unref0 (list);
}

static void
____lambda156__tuba_network_node_callback (JsonNode* node,
                                           gpointer self,
                                           GError** error)
{
	___lambda156_ (self, node, error);
}

static void
_vala_array_add53 (gchar** * array,
                   gint* length,
                   gint* size,
                   gchar* value)
{
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (gchar*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}

static gboolean
tuba_instance_account_gather_fav_lists_co (TubaInstanceAccountGatherFavListsData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = tuba_settings;
	_data_->_tmp2_ = 0;
	_data_->_tmp1_ = tuba_settings_get_favorite_lists_ids (_data_->_tmp0_, &_data_->_tmp2_);
	_data_->_tmp1__length1 = _data_->_tmp2_;
	_data_->_tmp3_ = _data_->_tmp1_;
	_data_->_tmp3__length1 = _data_->_tmp1__length1;
	if (_data_->_tmp3__length1 == 0) {
		_data_->_tmp4_ = _data_->self->list_places;
		tuba_instance_account_register_extra (_data_->self, _data_->_tmp4_, NULL, (gint) 0);
		g_task_return_pointer (_data_->_async_result, _data_, NULL);
		if (_data_->_state_ != 0) {
			while (!g_task_get_completed (_data_->_async_result)) {
				g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
			}
		}
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp5_ = _g_object_ref0 (_data_->self);
	_data_->_tmp6_ = NULL;
	_data_->_tmp6_ = tuba_request_v2_new ("/api/v1/lists", TUBA_REQUEST_V2_METHOD_GET);
	tuba_request_v2_set_account (_data_->_tmp6_, _data_->_tmp5_);
	_g_object_unref0 (_data_->_tmp5_);
	_data_->req = _data_->_tmp6_;
	{
		_data_->_data49_ = g_slice_new0 (Block49Data);
		_data_->_data49_->_ref_count_ = 1;
		_data_->_data49_->self = g_object_ref (_data_->self);
		_data_->_tmp7_ = _data_->req;
		_data_->_state_ = 1;
		tuba_request_v2_exec (_data_->_tmp7_, tuba_instance_account_gather_fav_lists_ready, _data_);
		return FALSE;
		_state_1:
		_data_->_tmp8_ = tuba_request_v2_exec_finish (_data_->_tmp7_, _data_->_res_, NULL, &_data_->_inner_error0_);
		_data_->in_stream = _data_->_tmp8_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			block49_data_unref (_data_->_data49_);
			_data_->_data49_ = NULL;
			goto __catch0_g_error;
		}
		_data_->_tmp9_ = _data_->in_stream;
		_data_->_state_ = 2;
		tuba_network_get_parser_from_inputstream_async (_data_->_tmp9_, NULL, tuba_instance_account_gather_fav_lists_ready, _data_);
		return FALSE;
		_state_2:
		_data_->_tmp10_ = tuba_network_get_parser_from_inputstream_finish (_data_->_res_, &_data_->_inner_error0_);
		_data_->parser = _data_->_tmp10_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			_g_object_unref0 (_data_->in_stream);
			block49_data_unref (_data_->_data49_);
			_data_->_data49_ = NULL;
			goto __catch0_g_error;
		}
		_data_->_tmp11_ = g_new0 (TubaPlace*, 0 + 1);
		_data_->_data49_->fav_lists = _data_->_tmp11_;
		_data_->_data49_->fav_lists_length1 = 0;
		_data_->_data49_->_fav_lists_size_ = _data_->_data49_->fav_lists_length1;
		_data_->_tmp12_ = g_new0 (gchar*, 0 + 1);
		_data_->_data49_->all_ids = _data_->_tmp12_;
		_data_->_data49_->all_ids_length1 = 0;
		_data_->_data49_->_all_ids_size_ = _data_->_data49_->all_ids_length1;
		_data_->_tmp13_ = _data_->parser;
		tuba_network_parse_array (_data_->_tmp13_, ____lambda156__tuba_network_node_callback, block49_data_ref (_data_->_data49_), block49_data_unref, &_data_->_inner_error0_);
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			_g_object_unref0 (_data_->parser);
			_g_object_unref0 (_data_->in_stream);
			block49_data_unref (_data_->_data49_);
			_data_->_data49_ = NULL;
			goto __catch0_g_error;
		}
		_data_->_tmp14_ = _data_->self->list_places;
		_data_->_tmp15_ = _data_->_data49_->fav_lists;
		_data_->_tmp15__length1 = _data_->_data49_->fav_lists_length1;
		tuba_instance_account_register_extra (_data_->self, _data_->_tmp14_, _data_->_tmp15_, (gint) _data_->_tmp15__length1);
		_data_->_tmp16_ = g_new0 (gchar*, 0 + 1);
		_data_->new_favs = _data_->_tmp16_;
		_data_->new_favs_length1 = 0;
		_data_->_new_favs_size_ = _data_->new_favs_length1;
		_data_->_tmp17_ = tuba_settings;
		_data_->_tmp19_ = 0;
		_data_->_tmp18_ = tuba_settings_get_favorite_lists_ids (_data_->_tmp17_, &_data_->_tmp19_);
		_data_->_tmp18__length1 = _data_->_tmp19_;
		_data_->_tmp20_ = _data_->_tmp18_;
		_data_->_tmp20__length1 = _data_->_tmp18__length1;
		{
			_data_->fav_id_collection_length1 = 0;
			_data_->_fav_id_collection_size_ = 0;
			_data_->fav_id_collection = _data_->_tmp20_;
			_data_->fav_id_collection_length1 = _data_->_tmp20__length1;
			for (_data_->fav_id_it = 0; _data_->fav_id_it < _data_->fav_id_collection_length1; _data_->fav_id_it = _data_->fav_id_it + 1) {
				_data_->_tmp21_ = g_strdup (_data_->fav_id_collection[_data_->fav_id_it]);
				_data_->fav_id = _data_->_tmp21_;
				{
					_data_->_tmp22_ = _data_->fav_id;
					_data_->_tmp23_ = _data_->_data49_->all_ids;
					_data_->_tmp23__length1 = _data_->_data49_->all_ids_length1;
					if (_vala_string_array_contains (_data_->_tmp23_, _data_->_tmp23__length1, _data_->_tmp22_)) {
						_data_->_tmp24_ = _data_->fav_id;
						_data_->_tmp25_ = g_strdup (_data_->_tmp24_);
						_vala_array_add53 (&_data_->new_favs, &_data_->new_favs_length1, &_data_->_new_favs_size_, _data_->_tmp25_);
					}
					_g_free0 (_data_->fav_id);
				}
			}
		}
		_data_->_tmp26_ = tuba_settings;
		_data_->_tmp27_ = _data_->new_favs;
		_data_->_tmp27__length1 = _data_->new_favs_length1;
		tuba_settings_set_favorite_lists_ids (_data_->_tmp26_, _data_->_tmp27_, _data_->_tmp27__length1);
		_data_->new_favs = (_vala_array_free (_data_->new_favs, _data_->new_favs_length1, (GDestroyNotify) g_free), NULL);
		_g_object_unref0 (_data_->parser);
		_g_object_unref0 (_data_->in_stream);
		block49_data_unref (_data_->_data49_);
		_data_->_data49_ = NULL;
	}
	goto __finally0;
	__catch0_g_error:
	{
		_data_->e = _data_->_inner_error0_;
		_data_->_inner_error0_ = NULL;
		_data_->_tmp28_ = _data_->e;
		_data_->_tmp29_ = g_strdup_printf ("%i", _data_->_tmp28_->code);
		_data_->_tmp30_ = _data_->_tmp29_;
		_data_->_tmp31_ = _data_->e;
		_data_->_tmp32_ = _data_->_tmp31_->message;
		_data_->_tmp33_ = string_to_string (_data_->_tmp32_);
		_data_->_tmp34_ = g_strconcat ("Couldn't fetch lists: ", _data_->_tmp30_, " ", _data_->_tmp33_, NULL);
		_data_->_tmp35_ = _data_->_tmp34_;
		g_warning ("InstanceAccount.vala:927: %s", _data_->_tmp35_);
		_g_free0 (_data_->_tmp35_);
		_g_free0 (_data_->_tmp30_);
		_g_error_free0 (_data_->e);
	}
	__finally0:
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		_g_object_unref0 (_data_->req);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error0_->message, g_quark_to_string (_data_->_inner_error0_->domain), _data_->_inner_error0_->code);
		g_clear_error (&_data_->_inner_error0_);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_g_object_unref0 (_data_->req);
	g_task_return_pointer (_data_->_async_result, _data_, NULL);
	if (_data_->_state_ != 0) {
		while (!g_task_get_completed (_data_->_async_result)) {
			g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
		}
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}

TubaViewsBase*
tuba_instance_account_set_as_sidebar_item (TubaViewsBase* view)
{
	TubaViewsBase* _tmp0_;
	TubaViewsBase* result;
	g_return_val_if_fail (view != NULL, NULL);
	tuba_views_base_set_is_sidebar_item (view, TRUE);
	tuba_views_base_set_show_back_button (view, FALSE);
	_tmp0_ = _g_object_ref0 (view);
	result = _tmp0_;
	return result;
}

static void
tuba_instance_account_init_notifications_data_free (gpointer _data)
{
	TubaInstanceAccountInitNotificationsData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->self);
	g_slice_free (TubaInstanceAccountInitNotificationsData, _data_);
}

void
tuba_instance_account_init_notifications (TubaInstanceAccount* self,
                                          GAsyncReadyCallback _callback_,
                                          gpointer _user_data_)
{
	TubaInstanceAccountInitNotificationsData* _data_;
	TubaInstanceAccount* _tmp0_;
	g_return_if_fail (self != NULL);
	_data_ = g_slice_new0 (TubaInstanceAccountInitNotificationsData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, tuba_instance_account_init_notifications_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	tuba_instance_account_init_notifications_co (_data_);
}

void
tuba_instance_account_init_notifications_finish (TubaInstanceAccount* self,
                                                 GAsyncResult* _res_)
{
	TubaInstanceAccountInitNotificationsData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), NULL);
}

static void
tuba_instance_account_init_notifications_ready (GObject* source_object,
                                                GAsyncResult* _res_,
                                                gpointer _user_data_)
{
	TubaInstanceAccountInitNotificationsData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	tuba_instance_account_init_notifications_co (_data_);
}

static gboolean
tuba_instance_account_init_notifications_co (TubaInstanceAccountInitNotificationsData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = tuba_views_notifications_get_notifications_excluded_types_query_param ();
	_data_->_tmp1_ = _data_->_tmp0_;
	_data_->_tmp2_ = string_to_string (_data_->_tmp1_);
	_data_->_tmp3_ = g_strconcat ("/api/v1/notifications", _data_->_tmp2_, NULL);
	_data_->_tmp4_ = _data_->_tmp3_;
	_data_->_tmp5_ = _g_object_ref0 (_data_->self);
	_data_->_tmp6_ = NULL;
	_data_->_tmp6_ = tuba_request_v2_new (_data_->_tmp4_, TUBA_REQUEST_V2_METHOD_GET);
	tuba_request_v2_set_account (_data_->_tmp6_, _data_->_tmp5_);
	_g_object_unref0 (_data_->_tmp5_);
	_data_->_tmp7_ = _data_->_tmp6_;
	_g_free0 (_data_->_tmp4_);
	_g_free0 (_data_->_tmp1_);
	_data_->req = _data_->_tmp7_;
	_data_->_tmp8_ = _data_->req;
	_data_->_tmp9_ = _data_->self->priv->_last_read_id;
	_data_->_tmp10_ = g_strdup_printf ("%i", _data_->_tmp9_);
	_data_->_tmp11_ = _data_->_tmp10_;
	tuba_request_v2_add_parameter (_data_->_tmp8_, "min_id", _data_->_tmp11_);
	_g_free0 (_data_->_tmp11_);
	{
		_data_->_tmp12_ = _data_->req;
		_data_->_state_ = 1;
		tuba_request_v2_exec (_data_->_tmp12_, tuba_instance_account_init_notifications_ready, _data_);
		return FALSE;
		_state_1:
		_data_->_tmp13_ = tuba_request_v2_exec_finish (_data_->_tmp12_, _data_->_res_, NULL, &_data_->_inner_error0_);
		_data_->in_stream = _data_->_tmp13_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
		_data_->_tmp14_ = _data_->in_stream;
		_data_->_state_ = 2;
		tuba_network_get_parser_from_inputstream_async (_data_->_tmp14_, NULL, tuba_instance_account_init_notifications_ready, _data_);
		return FALSE;
		_state_2:
		_data_->_tmp15_ = tuba_network_get_parser_from_inputstream_finish (_data_->_res_, &_data_->_inner_error0_);
		_data_->parser = _data_->_tmp15_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			_g_object_unref0 (_data_->in_stream);
			goto __catch0_g_error;
		}
		_data_->_tmp16_ = _data_->parser;
		_data_->_tmp17_ = tuba_network_get_array_mstd (_data_->_tmp16_);
		_data_->array = _data_->_tmp17_;
		_data_->_tmp18_ = _data_->array;
		if (_data_->_tmp18_ != NULL) {
			_data_->_tmp19_ = _data_->array;
			tuba_instance_account_set_unread_count (_data_->self, (gint) json_array_get_length (_data_->_tmp19_));
			_data_->_tmp20_ = _data_->self->priv->_unread_count;
			if (_data_->_tmp20_ > 0) {
				_data_->_tmp21_ = _data_->array;
				_data_->_tmp22_ = json_array_get_object_element (_data_->_tmp21_, (guint) 0);
				_data_->_tmp23_ = json_object_get_string_member_with_default (_data_->_tmp22_, "id", "-1");
				tuba_instance_account_set_last_received_id (_data_->self, atoi (_data_->_tmp23_));
			}
		}
		_json_array_unref0 (_data_->array);
		_g_object_unref0 (_data_->parser);
		_g_object_unref0 (_data_->in_stream);
	}
	goto __finally0;
	__catch0_g_error:
	{
		_data_->e = _data_->_inner_error0_;
		_data_->_inner_error0_ = NULL;
		_data_->_tmp24_ = _data_->e;
		_data_->_tmp25_ = g_strdup_printf ("%i", _data_->_tmp24_->code);
		_data_->_tmp26_ = _data_->_tmp25_;
		_data_->_tmp27_ = _data_->e;
		_data_->_tmp28_ = _data_->_tmp27_->message;
		_data_->_tmp29_ = string_to_string (_data_->_tmp28_);
		_data_->_tmp30_ = g_strconcat ("Couldn't init notifications: ", _data_->_tmp26_, " ", _data_->_tmp29_, NULL);
		_data_->_tmp31_ = _data_->_tmp30_;
		g_warning ("InstanceAccount.vala:953: %s", _data_->_tmp31_);
		_g_free0 (_data_->_tmp31_);
		_g_free0 (_data_->_tmp26_);
		_g_error_free0 (_data_->e);
	}
	__finally0:
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		_g_object_unref0 (_data_->req);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error0_->message, g_quark_to_string (_data_->_inner_error0_->domain), _data_->_inner_error0_->code);
		g_clear_error (&_data_->_inner_error0_);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_g_object_unref0 (_data_->req);
	g_task_return_pointer (_data_->_async_result, _data_, NULL);
	if (_data_->_state_ != 0) {
		while (!g_task_get_completed (_data_->_async_result)) {
			g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
		}
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}

static void
tuba_instance_account_real_check_notifications_data_free (gpointer _data)
{
	TubaInstanceAccountCheckNotificationsData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->self);
	g_slice_free (TubaInstanceAccountCheckNotificationsData, _data_);
}

static void
tuba_instance_account_real_check_notifications (TubaInstanceAccount* self,
                                                GAsyncReadyCallback _callback_,
                                                gpointer _user_data_)
{
	TubaInstanceAccountCheckNotificationsData* _data_;
	TubaInstanceAccount* _tmp0_;
	_data_ = g_slice_new0 (TubaInstanceAccountCheckNotificationsData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, tuba_instance_account_real_check_notifications_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	tuba_instance_account_real_check_notifications_co (_data_);
}

static void
tuba_instance_account_real_check_notifications_finish (TubaInstanceAccount* self,
                                                       GAsyncResult* _res_)
{
	TubaInstanceAccountCheckNotificationsData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), NULL);
}

static void
tuba_instance_account_check_notifications_ready (GObject* source_object,
                                                 GAsyncResult* _res_,
                                                 gpointer _user_data_)
{
	TubaInstanceAccountCheckNotificationsData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	tuba_instance_account_real_check_notifications_co (_data_);
}

static gpointer
_json_object_ref0 (gpointer self)
{
	return self ? json_object_ref (self) : NULL;
}

static gboolean
tuba_instance_account_real_check_notifications_co (TubaInstanceAccountCheckNotificationsData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		case 3:
		goto _state_3;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = _g_object_ref0 (_data_->self);
	_data_->_tmp1_ = NULL;
	_data_->_tmp1_ = tuba_request_v2_new ("/api/v1/markers?timeline[]=notifications", TUBA_REQUEST_V2_METHOD_GET);
	tuba_request_v2_set_account (_data_->_tmp1_, _data_->_tmp0_);
	_g_object_unref0 (_data_->_tmp0_);
	_data_->req = _data_->_tmp1_;
	{
		_data_->_tmp2_ = _data_->req;
		_data_->_state_ = 1;
		tuba_request_v2_exec (_data_->_tmp2_, tuba_instance_account_check_notifications_ready, _data_);
		return FALSE;
		_state_1:
		_data_->_tmp3_ = tuba_request_v2_exec_finish (_data_->_tmp2_, _data_->_res_, NULL, &_data_->_inner_error0_);
		_data_->in_stream = _data_->_tmp3_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
		_data_->_tmp4_ = _data_->in_stream;
		_data_->_state_ = 2;
		tuba_network_get_parser_from_inputstream_async (_data_->_tmp4_, NULL, tuba_instance_account_check_notifications_ready, _data_);
		return FALSE;
		_state_2:
		_data_->_tmp5_ = tuba_network_get_parser_from_inputstream_finish (_data_->_res_, &_data_->_inner_error0_);
		_data_->parser = _data_->_tmp5_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			_g_object_unref0 (_data_->in_stream);
			goto __catch0_g_error;
		}
		_data_->_tmp6_ = tuba_network;
		_data_->_tmp7_ = _data_->parser;
		_data_->_tmp8_ = tuba_network_parse (_data_->_tmp6_, _data_->_tmp7_);
		_data_->root = _data_->_tmp8_;
		if (!json_object_has_member (_data_->root, "notifications")) {
			_json_object_unref0 (_data_->root);
			_g_object_unref0 (_data_->parser);
			_g_object_unref0 (_data_->in_stream);
			_g_object_unref0 (_data_->req);
			g_task_return_pointer (_data_->_async_result, _data_, NULL);
			if (_data_->_state_ != 0) {
				while (!g_task_get_completed (_data_->_async_result)) {
					g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
				}
			}
			g_object_unref (_data_->_async_result);
			return FALSE;
		}
		_data_->_tmp9_ = json_object_get_object_member (_data_->root, "notifications");
		_data_->_tmp10_ = _json_object_ref0 (_data_->_tmp9_);
		_data_->notifications = _data_->_tmp10_;
		_data_->_tmp11_ = _data_->notifications;
		_data_->_tmp12_ = json_object_get_string_member_with_default (_data_->_tmp11_, "last_read_id", "-1");
		tuba_instance_account_set_last_read_id (_data_->self, atoi (_data_->_tmp12_));
		_data_->_state_ = 3;
		tuba_instance_account_init_notifications (_data_->self, tuba_instance_account_check_notifications_ready, _data_);
		return FALSE;
		_state_3:
		tuba_instance_account_init_notifications_finish (_data_->self, _data_->_res_);
		_json_object_unref0 (_data_->notifications);
		_json_object_unref0 (_data_->root);
		_g_object_unref0 (_data_->parser);
		_g_object_unref0 (_data_->in_stream);
	}
	goto __finally0;
	__catch0_g_error:
	{
		_data_->e = _data_->_inner_error0_;
		_data_->_inner_error0_ = NULL;
		_data_->_tmp13_ = _data_->e;
		_data_->_tmp14_ = g_strdup_printf ("%i", _data_->_tmp13_->code);
		_data_->_tmp15_ = _data_->_tmp14_;
		_data_->_tmp16_ = _data_->e;
		_data_->_tmp17_ = _data_->_tmp16_->message;
		_data_->_tmp18_ = string_to_string (_data_->_tmp17_);
		_data_->_tmp19_ = g_strconcat ("Couldn't check notifications: ", _data_->_tmp15_, " ", _data_->_tmp18_, NULL);
		_data_->_tmp20_ = _data_->_tmp19_;
		g_warning ("InstanceAccount.vala:968: %s", _data_->_tmp20_);
		_g_free0 (_data_->_tmp20_);
		_g_free0 (_data_->_tmp15_);
		_g_error_free0 (_data_->e);
	}
	__finally0:
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		_g_object_unref0 (_data_->req);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error0_->message, g_quark_to_string (_data_->_inner_error0_->domain), _data_->_inner_error0_->code);
		g_clear_error (&_data_->_inner_error0_);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_g_object_unref0 (_data_->req);
	g_task_return_pointer (_data_->_async_result, _data_, NULL);
	if (_data_->_state_ != 0) {
		while (!g_task_get_completed (_data_->_async_result)) {
			g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
		}
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}

void
tuba_instance_account_check_notifications (TubaInstanceAccount* self,
                                           GAsyncReadyCallback _callback_,
                                           gpointer _user_data_)
{
	TubaInstanceAccountClass* _klass_;
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->check_notifications) {
		_klass_->check_notifications (self, _callback_, _user_data_);
	}
}

void
tuba_instance_account_check_notifications_finish (TubaInstanceAccount* self,
                                                  GAsyncResult* _res_)
{
	TubaInstanceAccountClass* _klass_;
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->check_notifications_finish) {
		_klass_->check_notifications_finish (self, _res_);
	}
}

static void
tuba_instance_account_check_announcements_data_free (gpointer _data)
{
	TubaInstanceAccountCheckAnnouncementsData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->self);
	g_slice_free (TubaInstanceAccountCheckAnnouncementsData, _data_);
}

void
tuba_instance_account_check_announcements (TubaInstanceAccount* self,
                                           GAsyncReadyCallback _callback_,
                                           gpointer _user_data_)
{
	TubaInstanceAccountCheckAnnouncementsData* _data_;
	TubaInstanceAccount* _tmp0_;
	g_return_if_fail (self != NULL);
	_data_ = g_slice_new0 (TubaInstanceAccountCheckAnnouncementsData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, tuba_instance_account_check_announcements_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	tuba_instance_account_check_announcements_co (_data_);
}

void
tuba_instance_account_check_announcements_finish (TubaInstanceAccount* self,
                                                  GAsyncResult* _res_)
{
	TubaInstanceAccountCheckAnnouncementsData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), NULL);
}

static void
tuba_instance_account_check_announcements_ready (GObject* source_object,
                                                 GAsyncResult* _res_,
                                                 gpointer _user_data_)
{
	TubaInstanceAccountCheckAnnouncementsData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	tuba_instance_account_check_announcements_co (_data_);
}

static Block50Data*
block50_data_ref (Block50Data* _data50_)
{
	g_atomic_int_inc (&_data50_->_ref_count_);
	return _data50_;
}

static void
block50_data_unref (void * _userdata_)
{
	Block50Data* _data50_;
	_data50_ = (Block50Data*) _userdata_;
	if (g_atomic_int_dec_and_test (&_data50_->_ref_count_)) {
		TubaInstanceAccount* self;
		self = _data50_->self;
		_g_object_unref0 (self);
		g_slice_free (Block50Data, _data50_);
	}
}

static void
____lambda174_ (Block50Data* _data50_,
                JsonArray* array,
                guint i,
                JsonNode* node)
{
	TubaInstanceAccount* self;
	JsonObject* _tmp0_;
	self = _data50_->self;
	g_return_if_fail (array != NULL);
	g_return_if_fail (node != NULL);
	_tmp0_ = json_node_get_object (node);
	if (json_object_get_boolean_member_with_default (_tmp0_, "read", TRUE) == FALSE) {
		_data50_->t_unread_announcements += 1;
	}
}

static void
_____lambda174__json_array_foreach (JsonArray* array,
                                    guint index_,
                                    JsonNode* element_node,
                                    gpointer self)
{
	____lambda174_ (self, array, index_, element_node);
}

static gboolean
tuba_instance_account_check_announcements_co (TubaInstanceAccountCheckAnnouncementsData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = _g_object_ref0 (_data_->self);
	_data_->_tmp1_ = NULL;
	_data_->_tmp1_ = tuba_request_v2_new ("/api/v1/announcements", TUBA_REQUEST_V2_METHOD_GET);
	tuba_request_v2_set_account (_data_->_tmp1_, _data_->_tmp0_);
	_g_object_unref0 (_data_->_tmp0_);
	_data_->req = _data_->_tmp1_;
	{
		_data_->_tmp2_ = _data_->req;
		_data_->_state_ = 1;
		tuba_request_v2_exec (_data_->_tmp2_, tuba_instance_account_check_announcements_ready, _data_);
		return FALSE;
		_state_1:
		_data_->_tmp3_ = tuba_request_v2_exec_finish (_data_->_tmp2_, _data_->_res_, NULL, &_data_->_inner_error0_);
		_data_->in_stream = _data_->_tmp3_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
		_data_->_tmp4_ = _data_->in_stream;
		_data_->_state_ = 2;
		tuba_network_get_parser_from_inputstream_async (_data_->_tmp4_, NULL, tuba_instance_account_check_announcements_ready, _data_);
		return FALSE;
		_state_2:
		_data_->_tmp5_ = tuba_network_get_parser_from_inputstream_finish (_data_->_res_, &_data_->_inner_error0_);
		_data_->parser = _data_->_tmp5_;
		if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
			_g_object_unref0 (_data_->in_stream);
			goto __catch0_g_error;
		}
		_data_->_tmp6_ = _data_->parser;
		_data_->_tmp7_ = tuba_network_get_array_mstd (_data_->_tmp6_);
		_data_->array = _data_->_tmp7_;
		_data_->_tmp8_ = _data_->array;
		if (_data_->_tmp8_ != NULL) {
			_data_->_data50_ = g_slice_new0 (Block50Data);
			_data_->_data50_->_ref_count_ = 1;
			_data_->_data50_->self = g_object_ref (_data_->self);
			_data_->_data50_->t_unread_announcements = 0;
			_data_->_tmp9_ = _data_->array;
			json_array_foreach_element (_data_->_tmp9_, _____lambda174__json_array_foreach, _data_->_data50_);
			tuba_instance_account_set_unread_announcements (_data_->self, _data_->_data50_->t_unread_announcements);
			block50_data_unref (_data_->_data50_);
			_data_->_data50_ = NULL;
		}
		_json_array_unref0 (_data_->array);
		_g_object_unref0 (_data_->parser);
		_g_object_unref0 (_data_->in_stream);
	}
	goto __finally0;
	__catch0_g_error:
	{
		_data_->e = _data_->_inner_error0_;
		_data_->_inner_error0_ = NULL;
		_data_->_tmp10_ = _data_->e;
		_data_->_tmp11_ = g_strdup_printf ("%i", _data_->_tmp10_->code);
		_data_->_tmp12_ = _data_->_tmp11_;
		_data_->_tmp13_ = _data_->e;
		_data_->_tmp14_ = _data_->_tmp13_->message;
		_data_->_tmp15_ = string_to_string (_data_->_tmp14_);
		_data_->_tmp16_ = g_strconcat ("Couldn't check announcements: ", _data_->_tmp12_, " ", _data_->_tmp15_, NULL);
		_data_->_tmp17_ = _data_->_tmp16_;
		g_warning ("InstanceAccount.vala:986: %s", _data_->_tmp17_);
		_g_free0 (_data_->_tmp17_);
		_g_free0 (_data_->_tmp12_);
		_g_error_free0 (_data_->e);
	}
	__finally0:
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		_g_object_unref0 (_data_->req);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error0_->message, g_quark_to_string (_data_->_inner_error0_->domain), _data_->_inner_error0_->code);
		g_clear_error (&_data_->_inner_error0_);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_g_object_unref0 (_data_->req);
	g_task_return_pointer (_data_->_async_result, _data_, NULL);
	if (_data_->_state_ != 0) {
		while (!g_task_get_completed (_data_->_async_result)) {
			g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
		}
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}

static void
tuba_instance_account_read_notifications_data_free (gpointer _data)
{
	TubaInstanceAccountReadNotificationsData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->self);
	g_slice_free (TubaInstanceAccountReadNotificationsData, _data_);
}

void
tuba_instance_account_read_notifications (TubaInstanceAccount* self,
                                          gint up_to_id,
                                          GAsyncReadyCallback _callback_,
                                          gpointer _user_data_)
{
	TubaInstanceAccountReadNotificationsData* _data_;
	TubaInstanceAccount* _tmp0_;
	g_return_if_fail (self != NULL);
	_data_ = g_slice_new0 (TubaInstanceAccountReadNotificationsData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, tuba_instance_account_read_notifications_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	_data_->up_to_id = up_to_id;
	tuba_instance_account_read_notifications_co (_data_);
}

void
tuba_instance_account_read_notifications_finish (TubaInstanceAccount* self,
                                                 GAsyncResult* _res_)
{
	TubaInstanceAccountReadNotificationsData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), NULL);
}

static void
tuba_instance_account_read_notifications_ready (GObject* source_object,
                                                GAsyncResult* _res_,
                                                gpointer _user_data_)
{
	TubaInstanceAccountReadNotificationsData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	tuba_instance_account_read_notifications_co (_data_);
}

static gboolean
tuba_instance_account_read_notifications_co (TubaInstanceAccountReadNotificationsData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = g_strdup_printf ("%i", _data_->up_to_id);
	_data_->_tmp1_ = _data_->_tmp0_;
	_data_->_tmp2_ = g_strconcat ("Reading notifications up to id ", _data_->_tmp1_, NULL);
	_data_->_tmp3_ = _data_->_tmp2_;
	g_debug ("InstanceAccount.vala:991: %s", _data_->_tmp3_);
	_g_free0 (_data_->_tmp3_);
	_g_free0 (_data_->_tmp1_);
	_data_->_tmp4_ = _data_->self->priv->_last_read_id;
	if (_data_->up_to_id > _data_->_tmp4_) {
		tuba_instance_account_set_last_read_id (_data_->self, _data_->up_to_id);
		_data_->_tmp5_ = _data_->self->priv->_last_read_id;
		if (_data_->_tmp5_ != -1) {
			_data_->_tmp6_ = _g_object_ref0 (_data_->self);
			_data_->_tmp7_ = NULL;
			_data_->_tmp7_ = tuba_request_v2_new ("/api/v1/markers", TUBA_REQUEST_V2_METHOD_POST);
			tuba_request_v2_set_account (_data_->_tmp7_, _data_->_tmp6_);
			_g_object_unref0 (_data_->_tmp6_);
			_data_->req = _data_->_tmp7_;
			_data_->_tmp8_ = _data_->req;
			_data_->_tmp9_ = g_strdup_printf ("%i", _data_->up_to_id);
			_data_->_tmp10_ = _data_->_tmp9_;
			tuba_request_v2_add_form_data (_data_->_tmp8_, "notifications[last_read_id]", _data_->_tmp10_);
			_g_free0 (_data_->_tmp10_);
			{
				_data_->_tmp11_ = _data_->req;
				_data_->_state_ = 1;
				tuba_request_v2_exec (_data_->_tmp11_, tuba_instance_account_read_notifications_ready, _data_);
				return FALSE;
				_state_1:
				_data_->_tmp12_ = tuba_request_v2_exec_finish (_data_->_tmp11_, _data_->_res_, NULL, &_data_->_inner_error0_);
				_data_->_tmp13_ = _data_->_tmp12_;
				_g_object_unref0 (_data_->_tmp13_);
				if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
					goto __catch0_g_error;
				}
			}
			goto __finally0;
			__catch0_g_error:
			{
				_data_->e = _data_->_inner_error0_;
				_data_->_inner_error0_ = NULL;
				_data_->_tmp14_ = _data_->e;
				_data_->_tmp15_ = g_strdup_printf ("%i", _data_->_tmp14_->code);
				_data_->_tmp16_ = _data_->_tmp15_;
				_data_->_tmp17_ = _data_->e;
				_data_->_tmp18_ = _data_->_tmp17_->message;
				_data_->_tmp19_ = string_to_string (_data_->_tmp18_);
				_data_->_tmp20_ = g_strconcat ("Couldn't mark notifications as read: ", _data_->_tmp16_, " ", _data_->_tmp19_, NULL);
				_data_->_tmp21_ = _data_->_tmp20_;
				g_warning ("InstanceAccount.vala:1003: %s", _data_->_tmp21_);
				_g_free0 (_data_->_tmp21_);
				_g_free0 (_data_->_tmp16_);
				_g_error_free0 (_data_->e);
			}
			__finally0:
			if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
				_g_object_unref0 (_data_->req);
				g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error0_->message, g_quark_to_string (_data_->_inner_error0_->domain), _data_->_inner_error0_->code);
				g_clear_error (&_data_->_inner_error0_);
				g_object_unref (_data_->_async_result);
				return FALSE;
			}
			_data_->_tmp23_ = _data_->self->priv->_instance_info;
			if (_data_->_tmp23_ != NULL) {
				_data_->_tmp24_ = _data_->self->priv->_instance_info;
				_data_->_tmp25_ = tuba_api_instance_get_pleroma (_data_->_tmp24_);
				_data_->_tmp26_ = _data_->_tmp25_;
				_data_->_tmp22_ = _data_->_tmp26_ != NULL;
			} else {
				_data_->_tmp22_ = FALSE;
			}
			if (_data_->_tmp22_) {
				_data_->_tmp27_ = _g_object_ref0 (_data_->self);
				_data_->_tmp28_ = NULL;
				_data_->_tmp28_ = tuba_request_v2_new ("/api/v1/pleroma/notifications/read", TUBA_REQUEST_V2_METHOD_POST);
				tuba_request_v2_set_account (_data_->_tmp28_, _data_->_tmp27_);
				_g_object_unref0 (_data_->_tmp27_);
				_g_object_unref0 (_data_->req);
				_data_->req = _data_->_tmp28_;
				_data_->_tmp29_ = _data_->req;
				_data_->_tmp30_ = g_strdup_printf ("%i", _data_->up_to_id);
				_data_->_tmp31_ = _data_->_tmp30_;
				tuba_request_v2_add_form_data (_data_->_tmp29_, "max_id", _data_->_tmp31_);
				_g_free0 (_data_->_tmp31_);
				{
					_data_->_tmp32_ = _data_->req;
					_data_->_state_ = 2;
					tuba_request_v2_exec (_data_->_tmp32_, tuba_instance_account_read_notifications_ready, _data_);
					return FALSE;
					_state_2:
					_data_->_tmp33_ = tuba_request_v2_exec_finish (_data_->_tmp32_, _data_->_res_, NULL, &_data_->_inner_error0_);
					_data_->_tmp34_ = _data_->_tmp33_;
					_g_object_unref0 (_data_->_tmp34_);
					if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
						goto __catch1_g_error;
					}
				}
				goto __finally1;
				__catch1_g_error:
				{
					_data_->_vala1_e = _data_->_inner_error0_;
					_data_->_inner_error0_ = NULL;
					_data_->_tmp35_ = _data_->_vala1_e;
					_data_->_tmp36_ = g_strdup_printf ("%i", _data_->_tmp35_->code);
					_data_->_tmp37_ = _data_->_tmp36_;
					_data_->_tmp38_ = _data_->_vala1_e;
					_data_->_tmp39_ = _data_->_tmp38_->message;
					_data_->_tmp40_ = string_to_string (_data_->_tmp39_);
					_data_->_tmp41_ = g_strconcat ("Couldn't mark pleroma notifications as read: ", _data_->_tmp37_, " ", _data_->_tmp40_, NULL);
					_data_->_tmp42_ = _data_->_tmp41_;
					g_warning ("InstanceAccount.vala:1013: %s", _data_->_tmp42_);
					_g_free0 (_data_->_tmp42_);
					_g_free0 (_data_->_tmp37_);
					_g_error_free0 (_data_->_vala1_e);
				}
				__finally1:
				if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
					_g_object_unref0 (_data_->req);
					g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error0_->message, g_quark_to_string (_data_->_inner_error0_->domain), _data_->_inner_error0_->code);
					g_clear_error (&_data_->_inner_error0_);
					g_object_unref (_data_->_async_result);
					return FALSE;
				}
			}
			{
				_data_->_tmp43_ = _data_->self->priv->sent_notifications;
				_data_->_tmp44_ = gee_abstract_map_get_keys ((GeeAbstractMap*) _data_->_tmp43_);
				_data_->_tmp45_ = _data_->_tmp44_;
				_data_->_tmp46_ = _data_->_tmp45_;
				_data_->_tmp47_ = gee_iterable_iterator ((GeeIterable*) _data_->_tmp46_);
				_data_->_tmp48_ = _data_->_tmp47_;
				_g_object_unref0 (_data_->_tmp46_);
				_data_->_notification_id_it = _data_->_tmp48_;
				while (TRUE) {
					_data_->_tmp49_ = _data_->_notification_id_it;
					if (!gee_iterator_next (_data_->_tmp49_)) {
						break;
					}
					_data_->_tmp50_ = _data_->_notification_id_it;
					_data_->_tmp51_ = gee_iterator_get (_data_->_tmp50_);
					_data_->notification_id = (gchar*) _data_->_tmp51_;
					_data_->_tmp52_ = tuba_app;
					_data_->_tmp53_ = _data_->notification_id;
					g_application_withdraw_notification ((GApplication*) _data_->_tmp52_, _data_->_tmp53_);
					_g_free0 (_data_->notification_id);
				}
				_g_object_unref0 (_data_->_notification_id_it);
			}
			_data_->_tmp54_ = _data_->self->priv->sent_notifications;
			gee_abstract_map_clear ((GeeAbstractMap*) _data_->_tmp54_);
			_g_object_unref0 (_data_->req);
		}
	}
	tuba_instance_account_set_unread_count (_data_->self, 0);
	g_task_return_pointer (_data_->_async_result, _data_, NULL);
	if (_data_->_state_ != 0) {
		while (!g_task_get_completed (_data_->_async_result)) {
			g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
		}
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}

static Block51Data*
block51_data_ref (Block51Data* _data51_)
{
	g_atomic_int_inc (&_data51_->_ref_count_);
	return _data51_;
}

static void
block51_data_unref (void * _userdata_)
{
	Block51Data* _data51_;
	_data51_ = (Block51Data*) _userdata_;
	if (g_atomic_int_dec_and_test (&_data51_->_ref_count_)) {
		TubaInstanceAccount* self;
		self = _data51_->self;
		_g_free0 (_data51_->id);
		_g_object_unref0 (_data51_->obj);
		_g_object_unref0 (self);
		g_slice_free (Block51Data, _data51_);
	}
}

static void
__lambda202_ (Block51Data* _data51_,
              GObject* _obj,
              GAsyncResult* res)
{
	TubaInstanceAccount* self;
	TubaApplication* _tmp0_;
	const gchar* _tmp1_;
	GNotification* _tmp2_;
	GNotification* _tmp3_;
	self = _data51_->self;
	g_return_if_fail (res != NULL);
	_tmp0_ = tuba_app;
	_tmp1_ = _data51_->id;
	_tmp2_ = tuba_api_notification_to_toast_finish (_data51_->obj, res);
	_tmp3_ = _tmp2_;
	g_application_send_notification ((GApplication*) _tmp0_, _tmp1_, _tmp3_);
	_g_object_unref0 (_tmp3_);
}

static void
___lambda202__gasync_ready_callback (GObject* source_object,
                                     GAsyncResult* res,
                                     gpointer self)
{
	__lambda202_ (self, source_object, res);
	block51_data_unref (self);
}

void
tuba_instance_account_send_toast (TubaInstanceAccount* self,
                                  TubaAPINotification* obj)
{
	Block51Data* _data51_;
	TubaAPINotification* _tmp0_;
	gboolean _tmp1_ = FALSE;
	gboolean _tmp2_ = FALSE;
	const gchar* _tmp3_;
	const gchar* _tmp4_;
	const gchar* _tmp13_;
	const gchar* _tmp14_;
	gchar* _tmp15_;
	gint others = 0;
	gboolean _tmp16_ = FALSE;
	gboolean _tmp17_ = FALSE;
	TubaSettings* _tmp18_;
	gboolean _tmp19_;
	gboolean _tmp20_;
	GeeHashMap* _tmp47_;
	const gchar* _tmp48_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (obj != NULL);
	_data51_ = g_slice_new0 (Block51Data);
	_data51_->_ref_count_ = 1;
	_data51_->self = g_object_ref (self);
	_tmp0_ = _g_object_ref0 (obj);
	_g_object_unref0 (_data51_->obj);
	_data51_->obj = _tmp0_;
	_tmp3_ = tuba_api_notification_get_kind (_data51_->obj);
	_tmp4_ = _tmp3_;
	if (_tmp4_ == NULL) {
		_tmp2_ = TRUE;
	} else {
		const gchar* _tmp5_;
		const gchar* _tmp6_;
		_tmp5_ = tuba_api_notification_get_kind (_data51_->obj);
		_tmp6_ = _tmp5_;
		_tmp2_ = !_vala_string_array_contains (TUBA_INSTANCE_ACCOUNT_ALL_HANDLED_NOTIFICATION_TYPES, G_N_ELEMENTS (TUBA_INSTANCE_ACCOUNT_ALL_HANDLED_NOTIFICATION_TYPES), _tmp6_);
	}
	if (_tmp2_) {
		_tmp1_ = TRUE;
	} else {
		const gchar* _tmp7_;
		const gchar* _tmp8_;
		TubaSettings* _tmp9_;
		gchar** _tmp10_;
		gint _tmp10__length1;
		gint _tmp11_ = 0;
		gchar** _tmp12_;
		gint _tmp12__length1;
		_tmp7_ = tuba_api_notification_get_kind (_data51_->obj);
		_tmp8_ = _tmp7_;
		_tmp9_ = tuba_settings;
		_tmp10_ = tuba_settings_get_muted_notification_types (_tmp9_, &_tmp11_);
		_tmp10__length1 = _tmp11_;
		_tmp12_ = _tmp10_;
		_tmp12__length1 = _tmp10__length1;
		_tmp1_ = _vala_string_array_contains (_tmp12_, _tmp12__length1, _tmp8_);
	}
	if (_tmp1_) {
		block51_data_unref (_data51_);
		_data51_ = NULL;
		return;
	}
	_tmp13_ = tuba_api_account_get_id ((TubaAPIAccount*) self);
	_tmp14_ = _tmp13_;
	_tmp15_ = g_strdup (_tmp14_);
	_data51_->id = _tmp15_;
	others = 0;
	_tmp18_ = tuba_settings;
	_tmp19_ = tuba_settings_get_group_push_notifications (_tmp18_);
	_tmp20_ = _tmp19_;
	if (_tmp20_) {
		TubaAPIStatus* _tmp21_;
		TubaAPIStatus* _tmp22_;
		_tmp21_ = tuba_api_notification_get_status (_data51_->obj);
		_tmp22_ = _tmp21_;
		_tmp17_ = _tmp22_ != NULL;
	} else {
		_tmp17_ = FALSE;
	}
	if (_tmp17_) {
		const gchar* _tmp23_;
		const gchar* _tmp24_;
		_tmp23_ = tuba_api_notification_get_kind (_data51_->obj);
		_tmp24_ = _tmp23_;
		_tmp16_ = _vala_string_array_contains (TUBA_INSTANCE_ACCOUNT_GROUPED_KINDS, G_N_ELEMENTS (TUBA_INSTANCE_ACCOUNT_GROUPED_KINDS), _tmp24_);
	} else {
		_tmp16_ = FALSE;
	}
	if (_tmp16_) {
		const gchar* _tmp25_;
		const gchar* _tmp26_;
		TubaAPIStatus* _tmp27_;
		TubaAPIStatus* _tmp28_;
		const gchar* _tmp29_;
		const gchar* _tmp30_;
		const gchar* _tmp31_;
		const gchar* _tmp32_;
		const gchar* _tmp33_;
		const gchar* _tmp34_;
		gchar* _tmp35_;
		GeeHashMap* _tmp36_;
		const gchar* _tmp37_;
		_tmp25_ = _data51_->id;
		_tmp26_ = string_to_string (_tmp25_);
		_tmp27_ = tuba_api_notification_get_status (_data51_->obj);
		_tmp28_ = _tmp27_;
		_tmp29_ = tuba_api_status_get_id (_tmp28_);
		_tmp30_ = _tmp29_;
		_tmp31_ = string_to_string (_tmp30_);
		_tmp32_ = tuba_api_notification_get_kind (_data51_->obj);
		_tmp33_ = _tmp32_;
		_tmp34_ = string_to_string (_tmp33_);
		_tmp35_ = g_strconcat (_tmp26_, "-", _tmp31_, "-", _tmp34_, NULL);
		_g_free0 (_data51_->id);
		_data51_->id = _tmp35_;
		_tmp36_ = self->priv->sent_notifications;
		_tmp37_ = _data51_->id;
		if (gee_abstract_map_has_key ((GeeAbstractMap*) _tmp36_, _tmp37_)) {
			GeeHashMap* _tmp38_;
			const gchar* _tmp39_;
			gpointer _tmp40_;
			_tmp38_ = self->priv->sent_notifications;
			_tmp39_ = _data51_->id;
			_tmp40_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp38_, _tmp39_);
			others = ((gint) ((gintptr) _tmp40_)) + 1;
		}
	} else {
		const gchar* _tmp41_;
		const gchar* _tmp42_;
		const gchar* _tmp43_;
		const gchar* _tmp44_;
		const gchar* _tmp45_;
		gchar* _tmp46_;
		_tmp41_ = _data51_->id;
		_tmp42_ = string_to_string (_tmp41_);
		_tmp43_ = tuba_api_notification_get_id (_data51_->obj);
		_tmp44_ = _tmp43_;
		_tmp45_ = string_to_string (_tmp44_);
		_tmp46_ = g_strconcat (_tmp42_, "-", _tmp45_, NULL);
		_g_free0 (_data51_->id);
		_data51_->id = _tmp46_;
	}
	_tmp47_ = self->priv->sent_notifications;
	_tmp48_ = _data51_->id;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp47_, _tmp48_, (gpointer) ((gintptr) others));
	tuba_api_notification_to_toast (_data51_->obj, self, others, ___lambda202__gasync_ready_callback, block51_data_ref (_data51_));
	block51_data_unref (_data51_);
	_data51_ = NULL;
}

static gchar*
tuba_instance_account_real_get_stream_url (TubaInstanceAccount* self)
{
	gboolean _tmp0_ = FALSE;
	const gchar* _tmp1_;
	const gchar* _tmp3_;
	const gchar* _tmp4_;
	const gchar* _tmp5_;
	const gchar* _tmp6_;
	gchar* _tmp7_;
	gchar* result;
	_tmp1_ = self->priv->_instance;
	if (_tmp1_ == NULL) {
		_tmp0_ = TRUE;
	} else {
		const gchar* _tmp2_;
		_tmp2_ = self->priv->_access_token;
		_tmp0_ = _tmp2_ == NULL;
	}
	if (_tmp0_) {
		result = NULL;
		return result;
	}
	_tmp3_ = self->priv->_instance;
	_tmp4_ = string_to_string (_tmp3_);
	_tmp5_ = self->priv->_access_token;
	_tmp6_ = string_to_string (_tmp5_);
	_tmp7_ = g_strconcat (_tmp4_, "/api/v1/streaming?stream=user:notification&access_token=", _tmp6_, NULL);
	result = _tmp7_;
	return result;
}

gchar*
tuba_instance_account_get_stream_url (TubaInstanceAccount* self)
{
	TubaInstanceAccountClass* _klass_;
	g_return_val_if_fail (self != NULL, NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->get_stream_url) {
		return _klass_->get_stream_url (self);
	}
	return NULL;
}

static void
tuba_instance_account_on_notification_event (TubaInstanceAccount* self,
                                             TubaStreamableEvent* ev)
{
	GError* _inner_error0_ = NULL;
	g_return_if_fail (self != NULL);
	g_return_if_fail (ev != NULL);
	{
		JsonNode* _tmp0_ = NULL;
		JsonNode* _tmp1_;
		TubaAPINotification* entity = NULL;
		gpointer _tmp2_;
		TubaAPINotification* _tmp3_;
		_tmp1_ = tuba_streamable_event_get_node (ev, &_inner_error0_);
		_tmp0_ = _tmp1_;
		if (G_UNLIKELY (_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
		_tmp2_ = tuba_instance_account_create_entity (self, TUBA_API_TYPE_NOTIFICATION, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp0_, &_inner_error0_);
		entity = (TubaAPINotification*) _tmp2_;
		if (G_UNLIKELY (_inner_error0_ != NULL)) {
			__vala_JsonNode_free0 (_tmp0_);
			goto __catch0_g_error;
		}
		_tmp3_ = entity;
		tuba_instance_account_on_notification_received (self, _tmp3_);
		_g_object_unref0 (entity);
		__vala_JsonNode_free0 (_tmp0_);
	}
	goto __finally0;
	__catch0_g_error:
	{
		GError* e = NULL;
		GError* _tmp4_;
		const gchar* _tmp5_;
		const gchar* _tmp6_;
		gchar* _tmp7_;
		gchar* _tmp8_;
		e = _inner_error0_;
		_inner_error0_ = NULL;
		_tmp4_ = e;
		_tmp5_ = _tmp4_->message;
		_tmp6_ = string_to_string (_tmp5_);
		_tmp7_ = g_strconcat ("on_notification_event: ", _tmp6_, NULL);
		_tmp8_ = _tmp7_;
		g_warning ("InstanceAccount.vala:1095: %s", _tmp8_);
		_g_free0 (_tmp8_);
		_g_error_free0 (e);
	}
	__finally0:
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error0_->message, g_quark_to_string (_inner_error0_->domain), _inner_error0_->code);
		g_clear_error (&_inner_error0_);
		return;
	}
}

static void
tuba_instance_account_real_on_notification_received (TubaInstanceAccount* self,
                                                     TubaAPINotification* entity)
{
	gboolean _tmp0_ = FALSE;
	TubaAPIStatus* _tmp1_;
	TubaAPIStatus* _tmp2_;
	const gchar* _tmp9_;
	const gchar* _tmp10_;
	gint id = 0;
	const gchar* _tmp12_;
	const gchar* _tmp13_;
	gint _tmp14_;
	g_return_if_fail (entity != NULL);
	_tmp1_ = tuba_api_notification_get_status (entity);
	_tmp2_ = _tmp1_;
	if (_tmp2_ != NULL) {
		TubaAPIStatus* _tmp3_;
		TubaAPIStatus* _tmp4_;
		TubaAPIStatus* _tmp5_;
		TubaAPIStatus* _tmp6_;
		gboolean _tmp7_;
		gboolean _tmp8_;
		_tmp3_ = tuba_api_notification_get_status (entity);
		_tmp4_ = _tmp3_;
		_tmp5_ = tuba_api_status_get_formal (_tmp4_);
		_tmp6_ = _tmp5_;
		_tmp7_ = tuba_api_status_get_tuba_filter_hidden (_tmp6_);
		_tmp8_ = _tmp7_;
		_tmp0_ = _tmp8_;
	} else {
		_tmp0_ = FALSE;
	}
	if (_tmp0_) {
		return;
	}
	_tmp9_ = tuba_api_notification_get_kind (entity);
	_tmp10_ = _tmp9_;
	if (g_strcmp0 (_tmp10_, TUBA_INSTANCE_ACCOUNT_KIND_FOLLOW_REQUEST) == 0) {
		gint _tmp11_;
		_tmp11_ = self->priv->_unreviewed_follow_requests;
		tuba_instance_account_set_unreviewed_follow_requests (self, _tmp11_ + 1);
	}
	_tmp12_ = tuba_api_notification_get_id (entity);
	_tmp13_ = _tmp12_;
	id = atoi (_tmp13_);
	_tmp14_ = self->priv->_last_received_id;
	if (id > _tmp14_) {
		const gchar* _tmp15_;
		const gchar* _tmp16_;
		gint _tmp17_ = 0;
		gchar** _tmp18_;
		gchar** _tmp19_;
		gint _tmp19__length1;
		gboolean _tmp20_;
		tuba_instance_account_set_last_received_id (self, id);
		_tmp15_ = tuba_api_notification_get_kind (entity);
		_tmp16_ = _tmp15_;
		_tmp18_ = tuba_instance_account_account_settings_notification_filters (self, &_tmp17_);
		_tmp19_ = _tmp18_;
		_tmp19__length1 = _tmp17_;
		_tmp20_ = !_vala_string_array_contains (_tmp19_, _tmp17_, _tmp16_);
		_tmp19_ = (_vala_array_free (_tmp19_, _tmp19__length1, (GDestroyNotify) g_free), NULL);
		if (_tmp20_) {
			gint _tmp21_;
			_tmp21_ = self->priv->_unread_count;
			tuba_instance_account_set_unread_count (self, _tmp21_ + 1);
		}
		tuba_instance_account_send_toast (self, entity);
	}
}

void
tuba_instance_account_on_notification_received (TubaInstanceAccount* self,
                                                TubaAPINotification* entity)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->on_notification_received) {
		_klass_->on_notification_received (self, entity);
	}
}

static void
tuba_instance_account_real_open_status_url (TubaInstanceAccount* self,
                                            const gchar* url)
{
	g_return_if_fail (url != NULL);
}

void
tuba_instance_account_open_status_url (TubaInstanceAccount* self,
                                       const gchar* url)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->open_status_url) {
		_klass_->open_status_url (self, url);
	}
}

static void
tuba_instance_account_real_answer_follow_request (TubaInstanceAccount* self,
                                                  const gchar* issuer_id,
                                                  const gchar* fr_id,
                                                  gboolean accept)
{
	g_return_if_fail (issuer_id != NULL);
	g_return_if_fail (fr_id != NULL);
}

void
tuba_instance_account_answer_follow_request (TubaInstanceAccount* self,
                                             const gchar* issuer_id,
                                             const gchar* fr_id,
                                             gboolean accept)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->answer_follow_request) {
		_klass_->answer_follow_request (self, issuer_id, fr_id, accept);
	}
}

static void
tuba_instance_account_real_follow_back (TubaInstanceAccount* self,
                                        const gchar* issuer_id,
                                        const gchar* acc_id)
{
	g_return_if_fail (issuer_id != NULL);
	g_return_if_fail (acc_id != NULL);
}

void
tuba_instance_account_follow_back (TubaInstanceAccount* self,
                                   const gchar* issuer_id,
                                   const gchar* acc_id)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->follow_back) {
		_klass_->follow_back (self, issuer_id, acc_id);
	}
}

static void
tuba_instance_account_real_reply_to_status_uri (TubaInstanceAccount* self,
                                                const gchar* issuer_id,
                                                const gchar* uri)
{
	g_return_if_fail (issuer_id != NULL);
	g_return_if_fail (uri != NULL);
}

void
tuba_instance_account_reply_to_status_uri (TubaInstanceAccount* self,
                                           const gchar* issuer_id,
                                           const gchar* uri)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->reply_to_status_uri) {
		_klass_->reply_to_status_uri (self, issuer_id, uri);
	}
}

static void
tuba_instance_account_real_remove_from_followers (TubaInstanceAccount* self,
                                                  const gchar* issuer_id,
                                                  const gchar* acc_id)
{
	g_return_if_fail (issuer_id != NULL);
	g_return_if_fail (acc_id != NULL);
}

void
tuba_instance_account_remove_from_followers (TubaInstanceAccount* self,
                                             const gchar* issuer_id,
                                             const gchar* acc_id)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->remove_from_followers) {
		_klass_->remove_from_followers (self, issuer_id, acc_id);
	}
}

static GSettings*
tuba_instance_account_account_settings (TubaInstanceAccount* self)
{
	TubaAccountStore* _tmp0_;
	TubaInstanceAccount* _tmp1_;
	TubaInstanceAccount* _tmp2_;
	GSettings* _tmp5_;
	GSettings* _tmp8_;
	GSettings* _tmp9_;
	GSettings* result;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = tuba_accounts;
	_tmp1_ = tuba_account_store_get_active (_tmp0_);
	_tmp2_ = _tmp1_;
	if (_tmp2_ == self) {
		TubaSettings* _tmp3_;
		GSettings* _tmp4_;
		_tmp3_ = tuba_settings;
		_tmp4_ = _g_object_ref0 ((GSettings*) _tmp3_);
		result = _tmp4_;
		return result;
	}
	_tmp5_ = self->priv->_account_settings;
	if (_tmp5_ == NULL) {
		const gchar* _tmp6_;
		TubaSettingsAccount* _tmp7_;
		_tmp6_ = self->priv->_uuid;
		_tmp7_ = tuba_settings_account_new (_tmp6_);
		_g_object_unref0 (self->priv->_account_settings);
		self->priv->_account_settings = (GSettings*) _tmp7_;
	}
	_tmp8_ = self->priv->_account_settings;
	_tmp9_ = _g_object_ref0 (_tmp8_);
	result = _tmp9_;
	return result;
}

static gchar**
_vala_array_dup35 (gchar** self,
                   gssize length)
{
	if (length >= 0) {
		gchar** result;
		gssize i;
		result = g_new0 (gchar*, length + 1);
		for (i = 0; i < length; i++) {
			gchar* _tmp0_;
			_tmp0_ = g_strdup (self[i]);
			result[i] = _tmp0_;
		}
		return result;
	}
	return NULL;
}

static gchar**
_vala_array_dup36 (gchar** self,
                   gssize length)
{
	if (length >= 0) {
		gchar** result;
		gssize i;
		result = g_new0 (gchar*, length + 1);
		for (i = 0; i < length; i++) {
			gchar* _tmp0_;
			_tmp0_ = g_strdup (self[i]);
			result[i] = _tmp0_;
		}
		return result;
	}
	return NULL;
}

static gchar**
tuba_instance_account_account_settings_notification_filters (TubaInstanceAccount* self,
                                                             gint* result_length1)
{
	TubaAccountStore* _tmp0_;
	TubaInstanceAccount* _tmp1_;
	TubaInstanceAccount* _tmp2_;
	gchar** result;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = tuba_accounts;
	_tmp1_ = tuba_account_store_get_active (_tmp0_);
	_tmp2_ = _tmp1_;
	if (_tmp2_ == self) {
		GSettings* _tmp3_;
		TubaSettings* _tmp4_;
		gchar** _tmp5_;
		gint _tmp5__length1;
		gint _tmp6_ = 0;
		gchar** _tmp7_;
		gint _tmp7__length1;
		gchar** _tmp8_;
		gint _tmp8__length1;
		gchar** _tmp9_;
		gint _tmp9__length1;
		gchar** _tmp10_;
		gint _tmp10__length1;
		_tmp3_ = tuba_instance_account_account_settings (self);
		_tmp4_ = G_TYPE_CHECK_INSTANCE_CAST (_tmp3_, TUBA_TYPE_SETTINGS, TubaSettings);
		_tmp5_ = tuba_settings_get_notification_filters (_tmp4_, &_tmp6_);
		_tmp5__length1 = _tmp6_;
		_tmp7_ = _tmp5_;
		_tmp7__length1 = _tmp5__length1;
		_tmp8_ = (_tmp7_ != NULL) ? _vala_array_dup35 (_tmp7_, _tmp7__length1) : _tmp7_;
		_tmp8__length1 = _tmp7__length1;
		_tmp9_ = _tmp8_;
		_tmp9__length1 = _tmp8__length1;
		_g_object_unref0 (_tmp4_);
		_tmp10_ = _tmp9_;
		_tmp10__length1 = _tmp9__length1;
		if (result_length1) {
			*result_length1 = _tmp10__length1;
		}
		result = _tmp10_;
		return result;
	} else {
		GSettings* _tmp11_;
		TubaSettingsAccount* _tmp12_;
		gchar** _tmp13_;
		gint _tmp13__length1;
		gint _tmp14_ = 0;
		gchar** _tmp15_;
		gint _tmp15__length1;
		gchar** _tmp16_;
		gint _tmp16__length1;
		gchar** _tmp17_;
		gint _tmp17__length1;
		gchar** _tmp18_;
		gint _tmp18__length1;
		_tmp11_ = tuba_instance_account_account_settings (self);
		_tmp12_ = G_TYPE_CHECK_INSTANCE_CAST (_tmp11_, TUBA_SETTINGS_TYPE_ACCOUNT, TubaSettingsAccount);
		_tmp13_ = tuba_settings_account_get_notification_filters (_tmp12_, &_tmp14_);
		_tmp13__length1 = _tmp14_;
		_tmp15_ = _tmp13_;
		_tmp15__length1 = _tmp13__length1;
		_tmp16_ = (_tmp15_ != NULL) ? _vala_array_dup36 (_tmp15_, _tmp15__length1) : _tmp15_;
		_tmp16__length1 = _tmp15__length1;
		_tmp17_ = _tmp16_;
		_tmp17__length1 = _tmp16__length1;
		_g_object_unref0 (_tmp12_);
		_tmp18_ = _tmp17_;
		_tmp18__length1 = _tmp17__length1;
		if (result_length1) {
			*result_length1 = _tmp18__length1;
		}
		result = _tmp18_;
		return result;
	}
}

TubaInstanceAccount*
tuba_instance_account_construct (GType object_type)
{
	TubaInstanceAccount * self = NULL;
	self = (TubaInstanceAccount*) tuba_api_account_construct (object_type);
	return self;
}

TubaInstanceAccount*
tuba_instance_account_new (void)
{
	return tuba_instance_account_construct (TUBA_TYPE_INSTANCE_ACCOUNT);
}

TubaInstanceAccountInstanceFeatures
tuba_instance_account_get_tuba_instance_features (TubaInstanceAccount* self)
{
	TubaInstanceAccountInstanceFeatures result;
	g_return_val_if_fail (self != NULL, 0U);
	result = self->priv->_tuba_instance_features;
	return result;
}

void
tuba_instance_account_set_tuba_instance_features (TubaInstanceAccount* self,
                                                  TubaInstanceAccountInstanceFeatures value)
{
	TubaInstanceAccountInstanceFeatures old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_tuba_instance_features (self);
	if (old_value != value) {
		self->priv->_tuba_instance_features = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_INSTANCE_FEATURES_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_get_tuba_iceshrimp_api_key (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_tuba_iceshrimp_api_key;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_tuba_iceshrimp_api_key (TubaInstanceAccount* self,
                                                  const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_tuba_iceshrimp_api_key (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_tuba_iceshrimp_api_key);
		self->priv->_tuba_iceshrimp_api_key = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_ICESHRIMP_API_KEY_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_get_tuba_streaming_url (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_ = NULL;
	const gchar* _tmp1_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp1_ = self->priv->_tuba_streaming_url;
	if (_tmp1_ == NULL) {
		const gchar* _tmp2_;
		_tmp2_ = self->priv->_instance;
		_tmp0_ = _tmp2_;
	} else {
		const gchar* _tmp3_;
		_tmp3_ = self->priv->_tuba_streaming_url;
		_tmp0_ = _tmp3_;
	}
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_tuba_streaming_url (TubaInstanceAccount* self,
                                              const gchar* value)
{
	gchar* _tmp0_;
	g_return_if_fail (self != NULL);
	_tmp0_ = g_strdup (value);
	_g_free0 (self->priv->_tuba_streaming_url);
	self->priv->_tuba_streaming_url = _tmp0_;
	g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_STREAMING_URL_PROPERTY]);
}

gboolean
tuba_instance_account_get_admin_mode (TubaInstanceAccount* self)
{
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	result = self->priv->_admin_mode;
	return result;
}

void
tuba_instance_account_set_admin_mode (TubaInstanceAccount* self,
                                      gboolean value)
{
	gboolean old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_admin_mode (self);
	if (old_value != value) {
		self->priv->_admin_mode = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_ADMIN_MODE_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_get_backend (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_backend;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_backend (TubaInstanceAccount* self,
                                   const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_backend (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_backend);
		self->priv->_backend = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_BACKEND_PROPERTY]);
	}
}

TubaAPIInstance*
tuba_instance_account_get_instance_info (TubaInstanceAccount* self)
{
	TubaAPIInstance* result;
	TubaAPIInstance* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_instance_info;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_instance_info (TubaInstanceAccount* self,
                                         TubaAPIInstance* value)
{
	TubaAPIInstance* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_instance_info (self);
	if (old_value != value) {
		TubaAPIInstance* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_instance_info);
		self->priv->_instance_info = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_INSTANCE_INFO_PROPERTY]);
	}
}

GeeArrayList*
tuba_instance_account_get_instance_emojis (TubaInstanceAccount* self)
{
	GeeArrayList* result;
	GeeArrayList* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_instance_emojis;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_instance_emojis (TubaInstanceAccount* self,
                                           GeeArrayList* value)
{
	GeeArrayList* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_instance_emojis (self);
	if (old_value != value) {
		GeeArrayList* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_instance_emojis);
		self->priv->_instance_emojis = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_INSTANCE_EMOJIS_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_get_instance (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_instance;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_instance (TubaInstanceAccount* self,
                                    const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_instance (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_instance);
		self->priv->_instance = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_INSTANCE_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_get_client_id (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_client_id;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_client_id (TubaInstanceAccount* self,
                                     const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_client_id (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_client_id);
		self->priv->_client_id = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_CLIENT_ID_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_get_client_secret (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_client_secret;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_client_secret (TubaInstanceAccount* self,
                                         const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_client_secret (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_client_secret);
		self->priv->_client_secret = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_CLIENT_SECRET_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_get_access_token (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_access_token;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_access_token (TubaInstanceAccount* self,
                                        const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_access_token (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_access_token);
		self->priv->_access_token = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_ACCESS_TOKEN_PROPERTY]);
	}
}

gboolean
tuba_instance_account_get_needs_update (TubaInstanceAccount* self)
{
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	result = self->priv->_needs_update;
	return result;
}

void
tuba_instance_account_set_needs_update (TubaInstanceAccount* self,
                                        gboolean value)
{
	gboolean old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_needs_update (self);
	if (old_value != value) {
		self->priv->_needs_update = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_NEEDS_UPDATE_PROPERTY]);
	}
}

gboolean
tuba_instance_account_get_tuba_probably_has_notification_filters (TubaInstanceAccount* self)
{
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	result = self->priv->_tuba_probably_has_notification_filters;
	return result;
}

void
tuba_instance_account_set_tuba_probably_has_notification_filters (TubaInstanceAccount* self,
                                                                  gboolean value)
{
	gboolean old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_tuba_probably_has_notification_filters (self);
	if (old_value != value) {
		self->priv->_tuba_probably_has_notification_filters = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_PROBABLY_HAS_NOTIFICATION_FILTERS_PROPERTY]);
	}
}

gboolean
tuba_instance_account_get_tuba_revoked (TubaInstanceAccount* self)
{
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	result = self->priv->_tuba_revoked;
	return result;
}

void
tuba_instance_account_set_tuba_revoked (TubaInstanceAccount* self,
                                        gboolean value)
{
	gboolean old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_tuba_revoked (self);
	if (old_value != value) {
		self->priv->_tuba_revoked = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_REVOKED_PROPERTY]);
	}
}

gboolean
tuba_instance_account_get_tuba_cred_updated (TubaInstanceAccount* self)
{
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	result = self->priv->_tuba_cred_updated;
	return result;
}

void
tuba_instance_account_set_tuba_cred_updated (TubaInstanceAccount* self,
                                             gboolean value)
{
	gboolean old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_tuba_cred_updated (self);
	if (old_value != value) {
		self->priv->_tuba_cred_updated = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_CRED_UPDATED_PROPERTY]);
	}
}

gboolean
tuba_instance_account_get_tuba_verified_credentials (TubaInstanceAccount* self)
{
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	result = self->priv->_tuba_verified_credentials;
	return result;
}

void
tuba_instance_account_set_tuba_verified_credentials (TubaInstanceAccount* self,
                                                     gboolean value)
{
	gboolean old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_tuba_verified_credentials (self);
	if (old_value != value) {
		self->priv->_tuba_verified_credentials = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_VERIFIED_CREDENTIALS_PROPERTY]);
	}
}

TubaAPIInstanceV2APIVersions*
tuba_instance_account_get_tuba_api_versions (TubaInstanceAccount* self)
{
	TubaAPIInstanceV2APIVersions* result;
	TubaAPIInstanceV2APIVersions* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_tuba_api_versions;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_tuba_api_versions (TubaInstanceAccount* self,
                                             TubaAPIInstanceV2APIVersions* value)
{
	TubaAPIInstanceV2APIVersions* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_tuba_api_versions (self);
	if (old_value != value) {
		TubaAPIInstanceV2APIVersions* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_tuba_api_versions);
		self->priv->_tuba_api_versions = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_API_VERSIONS_PROPERTY]);
	}
}

gchar*
tuba_instance_account_get_handle_short (TubaInstanceAccount* self)
{
	gchar* result;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	gchar* _tmp3_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = tuba_api_account_get_username ((TubaAPIAccount*) self);
	_tmp1_ = _tmp0_;
	_tmp2_ = string_to_string (_tmp1_);
	_tmp3_ = g_strconcat ("@", _tmp2_, NULL);
	result = _tmp3_;
	return result;
}

gchar*
tuba_instance_account_get_handle (TubaInstanceAccount* self)
{
	gchar* result;
	gchar* _tmp0_;
	gchar* _tmp1_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = tuba_api_account_get_full_handle ((TubaAPIAccount*) self);
	_tmp1_ = _tmp0_;
	result = _tmp1_;
	return result;
}

gboolean
tuba_instance_account_get_is_active (TubaInstanceAccount* self)
{
	gboolean result;
	TubaAccountStore* _tmp0_;
	TubaInstanceAccount* _tmp1_;
	TubaInstanceAccount* _tmp2_;
	TubaAccountStore* _tmp3_;
	TubaInstanceAccount* _tmp4_;
	TubaInstanceAccount* _tmp5_;
	const gchar* _tmp6_;
	const gchar* _tmp7_;
	g_return_val_if_fail (self != NULL, FALSE);
	_tmp0_ = tuba_accounts;
	_tmp1_ = tuba_account_store_get_active (_tmp0_);
	_tmp2_ = _tmp1_;
	if (_tmp2_ == NULL) {
		result = FALSE;
		return result;
	}
	_tmp3_ = tuba_accounts;
	_tmp4_ = tuba_account_store_get_active (_tmp3_);
	_tmp5_ = _tmp4_;
	_tmp6_ = _tmp5_->priv->_access_token;
	_tmp7_ = self->priv->_access_token;
	result = g_strcmp0 (_tmp6_, _tmp7_) == 0;
	return result;
}

const gchar*
tuba_instance_account_get_uuid (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_uuid;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_uuid (TubaInstanceAccount* self,
                                const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_uuid (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_uuid);
		self->priv->_uuid = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UUID_PROPERTY]);
	}
}

gint
tuba_instance_account_get_unreviewed_follow_requests (TubaInstanceAccount* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, -1);
	result = self->priv->_unreviewed_follow_requests;
	return result;
}

void
tuba_instance_account_set_unreviewed_follow_requests (TubaInstanceAccount* self,
                                                      gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_unreviewed_follow_requests (self);
	if (old_value != value) {
		self->priv->_unreviewed_follow_requests = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UNREVIEWED_FOLLOW_REQUESTS_PROPERTY]);
	}
}

gint
tuba_instance_account_get_unread_announcements (TubaInstanceAccount* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, -1);
	result = self->priv->_unread_announcements;
	return result;
}

void
tuba_instance_account_set_unread_announcements (TubaInstanceAccount* self,
                                                gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_unread_announcements (self);
	if (old_value != value) {
		self->priv->_unread_announcements = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UNREAD_ANNOUNCEMENTS_PROPERTY]);
	}
}

gint
tuba_instance_account_get_filtered_notifications_count (TubaInstanceAccount* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, -1);
	result = self->priv->_filtered_notifications_count;
	return result;
}

void
tuba_instance_account_set_filtered_notifications_count (TubaInstanceAccount* self,
                                                        gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_filtered_notifications_count (self);
	if (old_value != value) {
		self->priv->_filtered_notifications_count = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_FILTERED_NOTIFICATIONS_COUNT_PROPERTY]);
	}
}

gint
tuba_instance_account_get_unread_count (TubaInstanceAccount* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, -1);
	result = self->priv->_unread_count;
	return result;
}

void
tuba_instance_account_set_unread_count (TubaInstanceAccount* self,
                                        gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_unread_count (self);
	if (old_value != value) {
		self->priv->_unread_count = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UNREAD_COUNT_PROPERTY]);
	}
}

gint
tuba_instance_account_get_last_read_id (TubaInstanceAccount* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, -1);
	result = self->priv->_last_read_id;
	return result;
}

void
tuba_instance_account_set_last_read_id (TubaInstanceAccount* self,
                                        gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_last_read_id (self);
	if (old_value != value) {
		self->priv->_last_read_id = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_LAST_READ_ID_PROPERTY]);
	}
}

gint
tuba_instance_account_get_last_received_id (TubaInstanceAccount* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, -1);
	result = self->priv->_last_received_id;
	return result;
}

void
tuba_instance_account_set_last_received_id (TubaInstanceAccount* self,
                                            gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_last_received_id (self);
	if (old_value != value) {
		self->priv->_last_received_id = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_LAST_RECEIVED_ID_PROPERTY]);
	}
}

gint
tuba_instance_account_get_tuba_last_fediwrapped_year (TubaInstanceAccount* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, -1);
	result = self->priv->_tuba_last_fediwrapped_year;
	return result;
}

void
tuba_instance_account_set_tuba_last_fediwrapped_year (TubaInstanceAccount* self,
                                                      gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_tuba_last_fediwrapped_year (self);
	if (old_value != value) {
		self->priv->_tuba_last_fediwrapped_year = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_LAST_FEDIWRAPPED_YEAR_PROPERTY]);
	}
}

static const gchar*
tuba_instance_account_real_get_t_connection_url (TubaStreamable* base)
{
	const gchar* result;
	TubaInstanceAccount* self;
	const gchar* _tmp0_;
	self = (TubaInstanceAccount*) base;
	_tmp0_ = self->priv->_t_connection_url;
	result = _tmp0_;
	return result;
}

static void
tuba_instance_account_real_set_t_connection_url (TubaStreamable* base,
                                                 const gchar* value)
{
	TubaInstanceAccount* self;
	gchar* old_value;
	self = (TubaInstanceAccount*) base;
	old_value = tuba_instance_account_real_get_t_connection_url (base);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_t_connection_url);
		self->priv->_t_connection_url = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_T_CONNECTION_URL_PROPERTY]);
	}
}

static gboolean
tuba_instance_account_real_get_subscribed (TubaStreamable* base)
{
	gboolean result;
	TubaInstanceAccount* self;
	self = (TubaInstanceAccount*) base;
	result = self->priv->_subscribed;
	return result;
}

static void
tuba_instance_account_real_set_subscribed (TubaStreamable* base,
                                           gboolean value)
{
	TubaInstanceAccount* self;
	gboolean old_value;
	self = (TubaInstanceAccount*) base;
	old_value = tuba_instance_account_real_get_subscribed (base);
	if (old_value != value) {
		self->priv->_subscribed = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_SUBSCRIBED_PROPERTY]);
	}
}

static void
tuba_instance_account_real_activated (TubaInstanceAccount* self)
{
	GSettings* _tmp0_;
	tuba_instance_account_bump_sidebar_items (self);
	tuba_instance_account_gather_instance_info (self, NULL, NULL);
	tuba_instance_account_gather_instance_custom_emojis (self, NULL, NULL);
	tuba_instance_account_gather_fav_lists (self, NULL, NULL);
	g_idle_add_full (G_PRIORITY_DEFAULT_IDLE, _tuba_instance_account_gather_fav_tags_gsource_func, g_object_ref (self), g_object_unref);
	tuba_instance_account_check_announcements (self, NULL, NULL);
	_tmp0_ = self->priv->_account_settings;
	if (_tmp0_ != NULL) {
		_g_object_unref0 (self->priv->_account_settings);
		self->priv->_account_settings = NULL;
	}
}

static void
tuba_instance_account_real_deactivated (TubaInstanceAccount* self)
{
}

static void
tuba_instance_account_real_added (TubaInstanceAccount* self)
{
	tuba_streamable_set_subscribed ((TubaStreamable*) self, TRUE);
	tuba_instance_account_check_notifications (self, NULL, NULL);
}

static void
tuba_instance_account_real_removed (TubaInstanceAccount* self)
{
	tuba_streamable_set_subscribed ((TubaStreamable*) self, FALSE);
}

static inline gpointer
tuba_instance_account_visibility_get_instance_private (TubaInstanceAccountVisibility* self)
{
	return G_STRUCT_MEMBER_P (self, TubaInstanceAccountVisibility_private_offset);
}

TubaInstanceAccountVisibility*
tuba_instance_account_visibility_construct (GType object_type)
{
	TubaInstanceAccountVisibility * self = NULL;
	self = (TubaInstanceAccountVisibility*) g_object_new (object_type, NULL);
	return self;
}

TubaInstanceAccountVisibility*
tuba_instance_account_visibility_new (void)
{
	return tuba_instance_account_visibility_construct (TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY);
}

const gchar*
tuba_instance_account_visibility_get_id (TubaInstanceAccountVisibility* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_id;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_visibility_set_id (TubaInstanceAccountVisibility* self,
                                         const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_visibility_get_id (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_id);
		self->priv->_id = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_ID_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_visibility_get_name (TubaInstanceAccountVisibility* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_name;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_visibility_set_name (TubaInstanceAccountVisibility* self,
                                           const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_visibility_get_name (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_name);
		self->priv->_name = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_NAME_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_visibility_get_icon_name (TubaInstanceAccountVisibility* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_icon_name;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_visibility_set_icon_name (TubaInstanceAccountVisibility* self,
                                                const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_visibility_get_icon_name (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_icon_name);
		self->priv->_icon_name = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_ICON_NAME_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_visibility_get_description (TubaInstanceAccountVisibility* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_description;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_visibility_set_description (TubaInstanceAccountVisibility* self,
                                                  const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_visibility_get_description (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_description);
		self->priv->_description = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_DESCRIPTION_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_visibility_get_small_icon_name (TubaInstanceAccountVisibility* self)
{
	const gchar* result;
	const gchar* _tmp0_ = NULL;
	const gchar* _tmp1_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp1_ = self->priv->_small_icon_name;
	_tmp0_ = _tmp1_;
	if (_tmp0_ == NULL) {
		const gchar* _tmp2_;
		_tmp2_ = self->priv->_icon_name;
		_tmp0_ = _tmp2_;
	}
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_visibility_set_small_icon_name (TubaInstanceAccountVisibility* self,
                                                      const gchar* value)
{
	gchar* _tmp0_;
	g_return_if_fail (self != NULL);
	_tmp0_ = g_strdup (value);
	_g_free0 (self->priv->_small_icon_name);
	self->priv->_small_icon_name = _tmp0_;
	g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_SMALL_ICON_NAME_PROPERTY]);
}

static void
tuba_instance_account_visibility_class_init (TubaInstanceAccountVisibilityClass * klass,
                                             gpointer klass_data)
{
	tuba_instance_account_visibility_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &TubaInstanceAccountVisibility_private_offset);
	G_OBJECT_CLASS (klass)->get_property = _vala_tuba_instance_account_visibility_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_tuba_instance_account_visibility_set_property;
	G_OBJECT_CLASS (klass)->finalize = tuba_instance_account_visibility_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_VISIBILITY_ID_PROPERTY, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_ID_PROPERTY] = g_param_spec_string ("id", "id", "id", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_VISIBILITY_NAME_PROPERTY, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_NAME_PROPERTY] = g_param_spec_string ("name", "name", "name", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_VISIBILITY_ICON_NAME_PROPERTY, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_ICON_NAME_PROPERTY] = g_param_spec_string ("icon-name", "icon-name", "icon-name", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_VISIBILITY_DESCRIPTION_PROPERTY, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_DESCRIPTION_PROPERTY] = g_param_spec_string ("description", "description", "description", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_VISIBILITY_SMALL_ICON_NAME_PROPERTY, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_SMALL_ICON_NAME_PROPERTY] = g_param_spec_string ("small-icon-name", "small-icon-name", "small-icon-name", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
}

static void
tuba_instance_account_visibility_instance_init (TubaInstanceAccountVisibility * self,
                                                gpointer klass)
{
	self->priv = tuba_instance_account_visibility_get_instance_private (self);
	self->priv->_small_icon_name = NULL;
}

static void
tuba_instance_account_visibility_finalize (GObject * obj)
{
	TubaInstanceAccountVisibility * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY, TubaInstanceAccountVisibility);
	_g_free0 (self->priv->_id);
	_g_free0 (self->priv->_name);
	_g_free0 (self->priv->_icon_name);
	_g_free0 (self->priv->_description);
	_g_free0 (self->priv->_small_icon_name);
	G_OBJECT_CLASS (tuba_instance_account_visibility_parent_class)->finalize (obj);
}

 G_GNUC_NO_INLINE static GType
tuba_instance_account_visibility_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (TubaInstanceAccountVisibilityClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) tuba_instance_account_visibility_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (TubaInstanceAccountVisibility), 0, (GInstanceInitFunc) tuba_instance_account_visibility_instance_init, NULL };
	GType tuba_instance_account_visibility_type_id;
	tuba_instance_account_visibility_type_id = g_type_register_static (G_TYPE_OBJECT, "TubaInstanceAccountVisibility", &g_define_type_info, G_TYPE_FLAG_NONE);
	TubaInstanceAccountVisibility_private_offset = g_type_add_instance_private (tuba_instance_account_visibility_type_id, sizeof (TubaInstanceAccountVisibilityPrivate));
	return tuba_instance_account_visibility_type_id;
}

GType
tuba_instance_account_visibility_get_type (void)
{
	static GType tuba_instance_account_visibility_type_id__once = 0;
	if (g_once_init_enter_pointer (&tuba_instance_account_visibility_type_id__once)) {
		GType tuba_instance_account_visibility_type_id;
		tuba_instance_account_visibility_type_id = tuba_instance_account_visibility_get_type_once ();
		g_once_init_leave_pointer (&tuba_instance_account_visibility_type_id__once, tuba_instance_account_visibility_type_id);
	}
	return tuba_instance_account_visibility_type_id__once;
}

static void
_vala_tuba_instance_account_visibility_get_property (GObject * object,
                                                     guint property_id,
                                                     GValue * value,
                                                     GParamSpec * pspec)
{
	TubaInstanceAccountVisibility * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY, TubaInstanceAccountVisibility);
	switch (property_id) {
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_ID_PROPERTY:
		g_value_set_string (value, tuba_instance_account_visibility_get_id (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_NAME_PROPERTY:
		g_value_set_string (value, tuba_instance_account_visibility_get_name (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_ICON_NAME_PROPERTY:
		g_value_set_string (value, tuba_instance_account_visibility_get_icon_name (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_DESCRIPTION_PROPERTY:
		g_value_set_string (value, tuba_instance_account_visibility_get_description (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_SMALL_ICON_NAME_PROPERTY:
		g_value_set_string (value, tuba_instance_account_visibility_get_small_icon_name (self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_tuba_instance_account_visibility_set_property (GObject * object,
                                                     guint property_id,
                                                     const GValue * value,
                                                     GParamSpec * pspec)
{
	TubaInstanceAccountVisibility * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY, TubaInstanceAccountVisibility);
	switch (property_id) {
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_ID_PROPERTY:
		tuba_instance_account_visibility_set_id (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_NAME_PROPERTY:
		tuba_instance_account_visibility_set_name (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_ICON_NAME_PROPERTY:
		tuba_instance_account_visibility_set_icon_name (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_DESCRIPTION_PROPERTY:
		tuba_instance_account_visibility_set_description (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_SMALL_ICON_NAME_PROPERTY:
		tuba_instance_account_visibility_set_small_icon_name (self, g_value_get_string (value));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static inline gpointer
tuba_instance_account_status_content_type_get_instance_private (TubaInstanceAccountStatusContentType* self)
{
	return G_STRUCT_MEMBER_P (self, TubaInstanceAccountStatusContentType_private_offset);
}

static gboolean
_tuba_instance_account_status_content_type_compare_lambda79_ (const gchar* a,
                                                              const gchar* b)
{
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	gboolean result;
	g_return_val_if_fail (a != NULL, FALSE);
	g_return_val_if_fail (b != NULL, FALSE);
	_tmp0_ = G_TYPE_CHECK_INSTANCE_CAST (a, TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentType)->priv->_mime;
	_tmp1_ = G_TYPE_CHECK_INSTANCE_CAST (b, TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentType)->priv->_mime;
	result = g_strcmp0 (_tmp0_, _tmp1_) == 0;
	return result;
}

static gboolean
__tuba_instance_account_status_content_type_compare_lambda79__gequal_func (gconstpointer a,
                                                                           gconstpointer b)
{
	gboolean result;
	result = _tuba_instance_account_status_content_type_compare_lambda79_ ((const gchar*) a, (const gchar*) b);
	return result;
}

static gint
string_index_of_char (const gchar* self,
                      gunichar c,
                      gint start_index)
{
	gchar* _result_ = NULL;
	gchar* _tmp0_;
	gchar* _tmp1_;
	gint result;
	g_return_val_if_fail (self != NULL, -1);
	_tmp0_ = g_utf8_strchr (((gchar*) self) + start_index, (gssize) -1, c);
	_result_ = _tmp0_;
	_tmp1_ = _result_;
	if (_tmp1_ != NULL) {
		gchar* _tmp2_;
		_tmp2_ = _result_;
		result = (gint) (_tmp2_ - ((gchar*) self));
		return result;
	} else {
		result = -1;
		return result;
	}
}

static gchar*
string_slice (const gchar* self,
              glong start,
              glong end)
{
	glong string_length = 0L;
	gint _tmp0_;
	gint _tmp1_;
	gboolean _tmp2_ = FALSE;
	gboolean _tmp3_ = FALSE;
	gchar* _tmp4_;
	gchar* result;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = strlen (self);
	_tmp1_ = _tmp0_;
	string_length = (glong) _tmp1_;
	if (start < ((glong) 0)) {
		start = string_length + start;
	}
	if (end < ((glong) 0)) {
		end = string_length + end;
	}
	if (start >= ((glong) 0)) {
		_tmp2_ = start <= string_length;
	} else {
		_tmp2_ = FALSE;
	}
	g_return_val_if_fail (_tmp2_, NULL);
	if (end >= ((glong) 0)) {
		_tmp3_ = end <= string_length;
	} else {
		_tmp3_ = FALSE;
	}
	g_return_val_if_fail (_tmp3_, NULL);
	g_return_val_if_fail (start <= end, NULL);
	_tmp4_ = g_strndup (((gchar*) self) + start, (gsize) (end - start));
	result = _tmp4_;
	return result;
}

TubaInstanceAccountStatusContentType*
tuba_instance_account_status_content_type_construct (GType object_type,
                                                     const gchar* content_type)
{
	TubaInstanceAccountStatusContentType * self = NULL;
	gchar* _tmp0_;
	gchar* _tmp1_;
	GQuark _tmp3_ = 0U;
	static GQuark _tmp2_label0 = 0;
	static GQuark _tmp2_label1 = 0;
	static GQuark _tmp2_label2 = 0;
	static GQuark _tmp2_label3 = 0;
	static GQuark _tmp2_label4 = 0;
	g_return_val_if_fail (content_type != NULL, NULL);
	self = (TubaInstanceAccountStatusContentType*) g_object_new (object_type, NULL);
	tuba_instance_account_status_content_type_set_mime (self, content_type);
	_tmp0_ = g_utf8_strdown (content_type, (gssize) -1);
	_tmp1_ = _tmp0_;
	_tmp3_ = (NULL == _tmp1_) ? 0 : g_quark_from_string (_tmp1_);
	g_free (_tmp1_);
	if (_tmp3_ == ((0 != _tmp2_label0) ? _tmp2_label0 : (_tmp2_label0 = g_quark_from_static_string ("text/plain")))) {
		switch (0) {
			default:
			{
				tuba_instance_account_status_content_type_set_icon_name (self, "tuba-paper-symbolic");
				tuba_instance_account_status_content_type_set_title (self, _ ("Plain Text"));
				tuba_instance_account_status_content_type_set_syntax (self, "fedi-basic");
				break;
			}
		}
	} else if (_tmp3_ == ((0 != _tmp2_label1) ? _tmp2_label1 : (_tmp2_label1 = g_quark_from_static_string ("text/html")))) {
		switch (0) {
			default:
			{
				tuba_instance_account_status_content_type_set_icon_name (self, "tuba-code-symbolic");
				tuba_instance_account_status_content_type_set_title (self, "HTML");
				tuba_instance_account_status_content_type_set_syntax (self, "fedi-html");
				break;
			}
		}
	} else if (_tmp3_ == ((0 != _tmp2_label2) ? _tmp2_label2 : (_tmp2_label2 = g_quark_from_static_string ("text/markdown")))) {
		switch (0) {
			default:
			{
				tuba_instance_account_status_content_type_set_icon_name (self, "tuba-markdown-symbolic");
				tuba_instance_account_status_content_type_set_title (self, "Markdown");
				tuba_instance_account_status_content_type_set_syntax (self, "fedi-markdown");
				break;
			}
		}
	} else if (_tmp3_ == ((0 != _tmp2_label3) ? _tmp2_label3 : (_tmp2_label3 = g_quark_from_static_string ("text/bbcode")))) {
		switch (0) {
			default:
			{
				tuba_instance_account_status_content_type_set_icon_name (self, "tuba-rich-text-symbolic");
				tuba_instance_account_status_content_type_set_title (self, "BBCode");
				tuba_instance_account_status_content_type_set_syntax (self, "fedi-basic");
				break;
			}
		}
	} else if (_tmp3_ == ((0 != _tmp2_label4) ? _tmp2_label4 : (_tmp2_label4 = g_quark_from_static_string ("text/x.misskeymarkdown")))) {
		switch (0) {
			default:
			{
				tuba_instance_account_status_content_type_set_icon_name (self, "tuba-rich-text-symbolic");
				tuba_instance_account_status_content_type_set_title (self, "MFM");
				tuba_instance_account_status_content_type_set_syntax (self, "fedi-basic");
				break;
			}
		}
	} else {
		switch (0) {
			default:
			{
				gint slash = 0;
				gint ct_l = 0;
				gint _tmp4_;
				gint _tmp5_;
				gboolean _tmp6_ = FALSE;
				tuba_instance_account_status_content_type_set_icon_name (self, "tuba-rich-text-symbolic");
				tuba_instance_account_status_content_type_set_syntax (self, "fedi-basic");
				slash = string_index_of_char (content_type, (gunichar) '/', 0);
				_tmp4_ = strlen (content_type);
				_tmp5_ = _tmp4_;
				ct_l = _tmp5_;
				if (slash == -1) {
					_tmp6_ = TRUE;
				} else {
					_tmp6_ = slash == ct_l;
				}
				if (_tmp6_) {
					gchar* _tmp7_;
					gchar* _tmp8_;
					_tmp7_ = g_utf8_strup (content_type, (gssize) -1);
					_tmp8_ = _tmp7_;
					tuba_instance_account_status_content_type_set_title (self, _tmp8_);
					_g_free0 (_tmp8_);
				} else {
					gchar* _tmp9_;
					gchar* _tmp10_;
					gchar* _tmp11_;
					gchar* _tmp12_;
					_tmp9_ = string_slice (content_type, (glong) (slash + 1), (glong) ct_l);
					_tmp10_ = _tmp9_;
					_tmp11_ = g_utf8_strup (_tmp10_, (gssize) -1);
					_tmp12_ = _tmp11_;
					tuba_instance_account_status_content_type_set_title (self, _tmp12_);
					_g_free0 (_tmp12_);
					_g_free0 (_tmp10_);
				}
				break;
			}
		}
	}
	return self;
}

TubaInstanceAccountStatusContentType*
tuba_instance_account_status_content_type_new (const gchar* content_type)
{
	return tuba_instance_account_status_content_type_construct (TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, content_type);
}

const gchar*
tuba_instance_account_status_content_type_get_mime (TubaInstanceAccountStatusContentType* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_mime;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_status_content_type_set_mime (TubaInstanceAccountStatusContentType* self,
                                                    const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_status_content_type_get_mime (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_mime);
		self->priv->_mime = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_MIME_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_status_content_type_get_icon_name (TubaInstanceAccountStatusContentType* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_icon_name;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_status_content_type_set_icon_name (TubaInstanceAccountStatusContentType* self,
                                                         const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_status_content_type_get_icon_name (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_icon_name);
		self->priv->_icon_name = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_ICON_NAME_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_status_content_type_get_title (TubaInstanceAccountStatusContentType* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_title;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_status_content_type_set_title (TubaInstanceAccountStatusContentType* self,
                                                     const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_status_content_type_get_title (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_title);
		self->priv->_title = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_TITLE_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_status_content_type_get_syntax (TubaInstanceAccountStatusContentType* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_syntax;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_status_content_type_set_syntax (TubaInstanceAccountStatusContentType* self,
                                                      const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_status_content_type_get_syntax (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_syntax);
		self->priv->_syntax = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_SYNTAX_PROPERTY]);
	}
}

static void
tuba_instance_account_status_content_type_class_init (TubaInstanceAccountStatusContentTypeClass * klass,
                                                      gpointer klass_data)
{
	tuba_instance_account_status_content_type_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &TubaInstanceAccountStatusContentType_private_offset);
	G_OBJECT_CLASS (klass)->get_property = _vala_tuba_instance_account_status_content_type_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_tuba_instance_account_status_content_type_set_property;
	G_OBJECT_CLASS (klass)->finalize = tuba_instance_account_status_content_type_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_MIME_PROPERTY, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_MIME_PROPERTY] = g_param_spec_string ("mime", "mime", "mime", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_ICON_NAME_PROPERTY, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_ICON_NAME_PROPERTY] = g_param_spec_string ("icon-name", "icon-name", "icon-name", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_TITLE_PROPERTY, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_TITLE_PROPERTY] = g_param_spec_string ("title", "title", "title", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_SYNTAX_PROPERTY, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_SYNTAX_PROPERTY] = g_param_spec_string ("syntax", "syntax", "syntax", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	tuba_instance_account_status_content_type_compare = __tuba_instance_account_status_content_type_compare_lambda79__gequal_func;
}

static void
tuba_instance_account_status_content_type_instance_init (TubaInstanceAccountStatusContentType * self,
                                                         gpointer klass)
{
	self->priv = tuba_instance_account_status_content_type_get_instance_private (self);
}

static void
tuba_instance_account_status_content_type_finalize (GObject * obj)
{
	TubaInstanceAccountStatusContentType * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentType);
	_g_free0 (self->priv->_mime);
	_g_free0 (self->priv->_icon_name);
	_g_free0 (self->priv->_title);
	_g_free0 (self->priv->_syntax);
	G_OBJECT_CLASS (tuba_instance_account_status_content_type_parent_class)->finalize (obj);
}

 G_GNUC_NO_INLINE static GType
tuba_instance_account_status_content_type_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (TubaInstanceAccountStatusContentTypeClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) tuba_instance_account_status_content_type_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (TubaInstanceAccountStatusContentType), 0, (GInstanceInitFunc) tuba_instance_account_status_content_type_instance_init, NULL };
	GType tuba_instance_account_status_content_type_type_id;
	tuba_instance_account_status_content_type_type_id = g_type_register_static (G_TYPE_OBJECT, "TubaInstanceAccountStatusContentType", &g_define_type_info, G_TYPE_FLAG_NONE);
	TubaInstanceAccountStatusContentType_private_offset = g_type_add_instance_private (tuba_instance_account_status_content_type_type_id, sizeof (TubaInstanceAccountStatusContentTypePrivate));
	return tuba_instance_account_status_content_type_type_id;
}

GType
tuba_instance_account_status_content_type_get_type (void)
{
	static GType tuba_instance_account_status_content_type_type_id__once = 0;
	if (g_once_init_enter_pointer (&tuba_instance_account_status_content_type_type_id__once)) {
		GType tuba_instance_account_status_content_type_type_id;
		tuba_instance_account_status_content_type_type_id = tuba_instance_account_status_content_type_get_type_once ();
		g_once_init_leave_pointer (&tuba_instance_account_status_content_type_type_id__once, tuba_instance_account_status_content_type_type_id);
	}
	return tuba_instance_account_status_content_type_type_id__once;
}

static void
_vala_tuba_instance_account_status_content_type_get_property (GObject * object,
                                                              guint property_id,
                                                              GValue * value,
                                                              GParamSpec * pspec)
{
	TubaInstanceAccountStatusContentType * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentType);
	switch (property_id) {
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_MIME_PROPERTY:
		g_value_set_string (value, tuba_instance_account_status_content_type_get_mime (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_ICON_NAME_PROPERTY:
		g_value_set_string (value, tuba_instance_account_status_content_type_get_icon_name (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_TITLE_PROPERTY:
		g_value_set_string (value, tuba_instance_account_status_content_type_get_title (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_SYNTAX_PROPERTY:
		g_value_set_string (value, tuba_instance_account_status_content_type_get_syntax (self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_tuba_instance_account_status_content_type_set_property (GObject * object,
                                                              guint property_id,
                                                              const GValue * value,
                                                              GParamSpec * pspec)
{
	TubaInstanceAccountStatusContentType * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentType);
	switch (property_id) {
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_MIME_PROPERTY:
		tuba_instance_account_status_content_type_set_mime (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_ICON_NAME_PROPERTY:
		tuba_instance_account_status_content_type_set_icon_name (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_TITLE_PROPERTY:
		tuba_instance_account_status_content_type_set_title (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_SYNTAX_PROPERTY:
		tuba_instance_account_status_content_type_set_syntax (self, g_value_get_string (value));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

void
tuba_instance_account_kind_copy (const TubaInstanceAccountKind* self,
                                 TubaInstanceAccountKind* dest)
{
	const gchar* _tmp0_;
	gchar* _tmp1_;
	const gchar* _tmp2_;
	gchar* _tmp3_;
	const gchar* _tmp4_;
	gchar* _tmp5_;
	_tmp0_ = (*self).icon;
	_tmp1_ = g_strdup (_tmp0_);
	_g_free0 ((*dest).icon);
	(*dest).icon = _tmp1_;
	_tmp2_ = (*self).description;
	_tmp3_ = g_strdup (_tmp2_);
	_g_free0 ((*dest).description);
	(*dest).description = _tmp3_;
	_tmp4_ = (*self).url;
	_tmp5_ = g_strdup (_tmp4_);
	_g_free0 ((*dest).url);
	(*dest).url = _tmp5_;
}

void
tuba_instance_account_kind_destroy (TubaInstanceAccountKind* self)
{
	_g_free0 ((*self).icon);
	_g_free0 ((*self).description);
	_g_free0 ((*self).url);
}

TubaInstanceAccountKind*
tuba_instance_account_kind_dup (const TubaInstanceAccountKind* self)
{
	TubaInstanceAccountKind* dup;
	dup = g_new0 (TubaInstanceAccountKind, 1);
	tuba_instance_account_kind_copy (self, dup);
	return dup;
}

void
tuba_instance_account_kind_free (TubaInstanceAccountKind* self)
{
	tuba_instance_account_kind_destroy (self);
	g_free (self);
}

 G_GNUC_NO_INLINE static GType
tuba_instance_account_kind_get_type_once (void)
{
	GType tuba_instance_account_kind_type_id;
	tuba_instance_account_kind_type_id = g_boxed_type_register_static ("TubaInstanceAccountKind", (GBoxedCopyFunc) tuba_instance_account_kind_dup, (GBoxedFreeFunc) tuba_instance_account_kind_free);
	return tuba_instance_account_kind_type_id;
}

GType
tuba_instance_account_kind_get_type (void)
{
	static GType tuba_instance_account_kind_type_id__once = 0;
	if (g_once_init_enter_pointer (&tuba_instance_account_kind_type_id__once)) {
		GType tuba_instance_account_kind_type_id;
		tuba_instance_account_kind_type_id = tuba_instance_account_kind_get_type_once ();
		g_once_init_leave_pointer (&tuba_instance_account_kind_type_id__once, tuba_instance_account_kind_type_id);
	}
	return tuba_instance_account_kind_type_id__once;
}

static void
_tuba_instance_account_on_notification_event_tuba_streamable_stream_event (TubaStreamable* _sender,
                                                                           TubaStreamableEvent* ev,
                                                                           gpointer self)
{
	tuba_instance_account_on_notification_event ((TubaInstanceAccount*) self, ev);
}

static void
_tuba_instance_account_on_network_change_g_object_notify (GObject* _sender,
                                                          GParamSpec* pspec,
                                                          gpointer self)
{
	tuba_instance_account_on_network_change ((TubaInstanceAccount*) self);
}

static GObject *
tuba_instance_account_constructor (GType type,
                                   guint n_construct_properties,
                                   GObjectConstructParam * construct_properties)
{
	GObject * obj;
	GObjectClass * parent_class;
	TubaInstanceAccount * self;
	gchar* _tmp0_;
	GListStore* _tmp1_;
	GListStore* _tmp2_;
	GListStore* _tmp3_;
	TubaApplication* _tmp4_;
	parent_class = G_OBJECT_CLASS (tuba_instance_account_parent_class);
	obj = parent_class->constructor (type, n_construct_properties, construct_properties);
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccount);
	tuba_streamable_construct_streamable ((TubaStreamable*) self);
	_tmp0_ = g_strconcat ("stream-event::", TUBA_INSTANCE_ACCOUNT_EVENT_NOTIFICATION, NULL);
	g_signal_connect_object ((TubaStreamable*) self, _tmp0_, (GCallback) _tuba_instance_account_on_notification_event_tuba_streamable_stream_event, self, 0);
	_g_free0 (_tmp0_);
	_tmp1_ = self->known_places;
	tuba_instance_account_register_known_places (self, _tmp1_);
	_tmp2_ = self->list_places;
	tuba_instance_account_register_extra (self, _tmp2_, NULL, (gint) 0);
	_tmp3_ = self->tags_places;
	tuba_instance_account_register_extra (self, _tmp3_, NULL, (gint) 0);
	_tmp4_ = tuba_app;
	g_signal_connect_object ((GObject*) _tmp4_, "notify::is-online", (GCallback) _tuba_instance_account_on_network_change_g_object_notify, self, 0);
	return obj;
}

static void
tuba_instance_account_class_init (TubaInstanceAccountClass * klass,
                                  gpointer klass_data)
{
	tuba_instance_account_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &TubaInstanceAccount_private_offset);
	((TubaInstanceAccountClass *) klass)->describe_kind = (void (*) (TubaInstanceAccount*, const gchar*, TubaInstanceAccountKind*, const gchar*, const gchar*, const gchar*)) tuba_instance_account_real_describe_kind;
	((TubaInstanceAccountClass *) klass)->register_known_places = (void (*) (TubaInstanceAccount*, GListStore*)) tuba_instance_account_real_register_known_places;
	((TubaInstanceAccountClass *) klass)->register_extra = (void (*) (TubaInstanceAccount*, GListStore*, TubaPlace**, gint)) tuba_instance_account_real_register_extra;
	((TubaInstanceAccountClass *) klass)->bump_sidebar_items = (void (*) (TubaInstanceAccount*)) tuba_instance_account_real_bump_sidebar_items;
	((TubaInstanceAccountClass *) klass)->check_notifications = (void (*) (TubaInstanceAccount*, GAsyncReadyCallback, gpointer)) tuba_instance_account_real_check_notifications;
	((TubaInstanceAccountClass *) klass)->check_notifications_finish = (void (*) (TubaInstanceAccount*, GAsyncResult*)) tuba_instance_account_real_check_notifications_finish;
	((TubaInstanceAccountClass *) klass)->get_stream_url = (gchar* (*) (TubaInstanceAccount*)) tuba_instance_account_real_get_stream_url;
	((TubaInstanceAccountClass *) klass)->on_notification_received = (void (*) (TubaInstanceAccount*, TubaAPINotification*)) tuba_instance_account_real_on_notification_received;
	((TubaInstanceAccountClass *) klass)->open_status_url = (void (*) (TubaInstanceAccount*, const gchar*)) tuba_instance_account_real_open_status_url;
	((TubaInstanceAccountClass *) klass)->answer_follow_request = (void (*) (TubaInstanceAccount*, const gchar*, const gchar*, gboolean)) tuba_instance_account_real_answer_follow_request;
	((TubaInstanceAccountClass *) klass)->follow_back = (void (*) (TubaInstanceAccount*, const gchar*, const gchar*)) tuba_instance_account_real_follow_back;
	((TubaInstanceAccountClass *) klass)->reply_to_status_uri = (void (*) (TubaInstanceAccount*, const gchar*, const gchar*)) tuba_instance_account_real_reply_to_status_uri;
	((TubaInstanceAccountClass *) klass)->remove_from_followers = (void (*) (TubaInstanceAccount*, const gchar*, const gchar*)) tuba_instance_account_real_remove_from_followers;
	((TubaInstanceAccountClass *) klass)->activated = tuba_instance_account_real_activated;
	((TubaInstanceAccountClass *) klass)->deactivated = tuba_instance_account_real_deactivated;
	((TubaInstanceAccountClass *) klass)->added = tuba_instance_account_real_added;
	((TubaInstanceAccountClass *) klass)->removed = tuba_instance_account_real_removed;
	G_OBJECT_CLASS (klass)->get_property = _vala_tuba_instance_account_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_tuba_instance_account_set_property;
	G_OBJECT_CLASS (klass)->constructor = tuba_instance_account_constructor;
	G_OBJECT_CLASS (klass)->finalize = tuba_instance_account_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_TUBA_INSTANCE_FEATURES_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_INSTANCE_FEATURES_PROPERTY] = g_param_spec_flags ("tuba-instance-features", "tuba-instance-features", "tuba-instance-features", TUBA_INSTANCE_ACCOUNT_TYPE_INSTANCE_FEATURES, TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_NONE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_TUBA_ICESHRIMP_API_KEY_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_ICESHRIMP_API_KEY_PROPERTY] = g_param_spec_string ("tuba-iceshrimp-api-key", "tuba-iceshrimp-api-key", "tuba-iceshrimp-api-key", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_TUBA_STREAMING_URL_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_STREAMING_URL_PROPERTY] = g_param_spec_string ("tuba-streaming-url", "tuba-streaming-url", "tuba-streaming-url", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_ADMIN_MODE_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_ADMIN_MODE_PROPERTY] = g_param_spec_boolean ("admin-mode", "admin-mode", "admin-mode", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_BACKEND_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_BACKEND_PROPERTY] = g_param_spec_string ("backend", "backend", "backend", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_INSTANCE_INFO_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_INSTANCE_INFO_PROPERTY] = g_param_spec_object ("instance-info", "instance-info", "instance-info", TUBA_API_TYPE_INSTANCE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_INSTANCE_EMOJIS_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_INSTANCE_EMOJIS_PROPERTY] = g_param_spec_object ("instance-emojis", "instance-emojis", "instance-emojis", GEE_TYPE_ARRAY_LIST, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_INSTANCE_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_INSTANCE_PROPERTY] = g_param_spec_string ("instance", "instance", "instance", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_CLIENT_ID_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_CLIENT_ID_PROPERTY] = g_param_spec_string ("client-id", "client-id", "client-id", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_CLIENT_SECRET_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_CLIENT_SECRET_PROPERTY] = g_param_spec_string ("client-secret", "client-secret", "client-secret", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_ACCESS_TOKEN_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_ACCESS_TOKEN_PROPERTY] = g_param_spec_string ("access-token", "access-token", "access-token", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_NEEDS_UPDATE_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_NEEDS_UPDATE_PROPERTY] = g_param_spec_boolean ("needs-update", "needs-update", "needs-update", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_TUBA_PROBABLY_HAS_NOTIFICATION_FILTERS_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_PROBABLY_HAS_NOTIFICATION_FILTERS_PROPERTY] = g_param_spec_boolean ("tuba-probably-has-notification-filters", "tuba-probably-has-notification-filters", "tuba-probably-has-notification-filters", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_TUBA_REVOKED_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_REVOKED_PROPERTY] = g_param_spec_boolean ("tuba-revoked", "tuba-revoked", "tuba-revoked", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_TUBA_CRED_UPDATED_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_CRED_UPDATED_PROPERTY] = g_param_spec_boolean ("tuba-cred-updated", "tuba-cred-updated", "tuba-cred-updated", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_TUBA_VERIFIED_CREDENTIALS_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_VERIFIED_CREDENTIALS_PROPERTY] = g_param_spec_boolean ("tuba-verified-credentials", "tuba-verified-credentials", "tuba-verified-credentials", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_TUBA_API_VERSIONS_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_API_VERSIONS_PROPERTY] = g_param_spec_object ("tuba-api-versions", "tuba-api-versions", "tuba-api-versions", TUBA_API_INSTANCE_V2_TYPE_API_VERSIONS, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_HANDLE_SHORT_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_HANDLE_SHORT_PROPERTY] = g_param_spec_string ("handle-short", "handle-short", "handle-short", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_HANDLE_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_HANDLE_PROPERTY] = g_param_spec_string ("handle", "handle", "handle", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_IS_ACTIVE_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_IS_ACTIVE_PROPERTY] = g_param_spec_boolean ("is-active", "is-active", "is-active", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_UUID_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UUID_PROPERTY] = g_param_spec_string ("uuid", "uuid", "uuid", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_UNREVIEWED_FOLLOW_REQUESTS_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UNREVIEWED_FOLLOW_REQUESTS_PROPERTY] = g_param_spec_int ("unreviewed-follow-requests", "unreviewed-follow-requests", "unreviewed-follow-requests", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_UNREAD_ANNOUNCEMENTS_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UNREAD_ANNOUNCEMENTS_PROPERTY] = g_param_spec_int ("unread-announcements", "unread-announcements", "unread-announcements", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_FILTERED_NOTIFICATIONS_COUNT_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_FILTERED_NOTIFICATIONS_COUNT_PROPERTY] = g_param_spec_int ("filtered-notifications-count", "filtered-notifications-count", "filtered-notifications-count", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_UNREAD_COUNT_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UNREAD_COUNT_PROPERTY] = g_param_spec_int ("unread-count", "unread-count", "unread-count", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_LAST_READ_ID_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_LAST_READ_ID_PROPERTY] = g_param_spec_int ("last-read-id", "last-read-id", "last-read-id", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_LAST_RECEIVED_ID_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_LAST_RECEIVED_ID_PROPERTY] = g_param_spec_int ("last-received-id", "last-received-id", "last-received-id", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_TUBA_LAST_FEDIWRAPPED_YEAR_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_LAST_FEDIWRAPPED_YEAR_PROPERTY] = g_param_spec_int ("tuba-last-fediwrapped-year", "tuba-last-fediwrapped-year", "tuba-last-fediwrapped-year", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_T_CONNECTION_URL_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_T_CONNECTION_URL_PROPERTY] = g_param_spec_string ("t-connection-url", "t-connection-url", "t-connection-url", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_SUBSCRIBED_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_SUBSCRIBED_PROPERTY] = g_param_spec_boolean ("subscribed", "subscribed", "subscribed", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	tuba_instance_account_signals[TUBA_INSTANCE_ACCOUNT_ACTIVATED_SIGNAL] = g_signal_new ("activated", TUBA_TYPE_INSTANCE_ACCOUNT, G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (TubaInstanceAccountClass, activated), NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0);
	tuba_instance_account_signals[TUBA_INSTANCE_ACCOUNT_DEACTIVATED_SIGNAL] = g_signal_new ("deactivated", TUBA_TYPE_INSTANCE_ACCOUNT, G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (TubaInstanceAccountClass, deactivated), NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0);
	tuba_instance_account_signals[TUBA_INSTANCE_ACCOUNT_ADDED_SIGNAL] = g_signal_new ("added", TUBA_TYPE_INSTANCE_ACCOUNT, G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (TubaInstanceAccountClass, added), NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0);
	tuba_instance_account_signals[TUBA_INSTANCE_ACCOUNT_REMOVED_SIGNAL] = g_signal_new ("removed", TUBA_TYPE_INSTANCE_ACCOUNT, G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (TubaInstanceAccountClass, removed), NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0);
}

static void
tuba_instance_account_tuba_streamable_interface_init (TubaStreamableIface * iface,
                                                      gpointer iface_data)
{
	tuba_instance_account_tuba_streamable_parent_iface = g_type_interface_peek_parent (iface);
	iface->get_stream_url = (gchar* (*) (TubaStreamable*)) tuba_instance_account_get_stream_url;
	iface->get_t_connection_url = tuba_instance_account_real_get_t_connection_url;
	iface->set_t_connection_url = tuba_instance_account_real_set_t_connection_url;
	iface->get_subscribed = tuba_instance_account_real_get_subscribed;
	iface->set_subscribed = tuba_instance_account_real_set_subscribed;
}

static void
tuba_instance_account_instance_init (TubaInstanceAccount * self,
                                     gpointer klass)
{
	TubaAPIInstanceV2APIVersions* _tmp0_;
	GListStore* _tmp1_;
	GListStore* _tmp2_;
	GListStore* _tmp3_;
	GeeHashMap* _tmp4_;
	GeeHashMap* _tmp5_;
	GListStore* _tmp6_;
	GListStore* _tmp7_;
	GeeHashMap* _tmp8_;
	self->priv = tuba_instance_account_get_instance_private (self);
	self->priv->_tuba_instance_features = TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_NONE;
	self->priv->_tuba_iceshrimp_api_key = NULL;
	self->priv->_tuba_streaming_url = NULL;
	self->priv->_admin_mode = FALSE;
	self->priv->_needs_update = FALSE;
	self->priv->_tuba_probably_has_notification_filters = FALSE;
	self->priv->_tuba_revoked = FALSE;
	self->priv->_tuba_cred_updated = FALSE;
	self->priv->_tuba_verified_credentials = FALSE;
	_tmp0_ = tuba_api_instance_v2_api_versions_new ();
	self->priv->_tuba_api_versions = _tmp0_;
	_tmp1_ = g_list_store_new (TUBA_TYPE_PLACE);
	self->known_places = _tmp1_;
	_tmp2_ = g_list_store_new (TUBA_TYPE_PLACE);
	self->list_places = _tmp2_;
	_tmp3_ = g_list_store_new (TUBA_TYPE_PLACE);
	self->tags_places = _tmp3_;
	_tmp4_ = gee_hash_map_new (G_TYPE_GTYPE, NULL, NULL, G_TYPE_GTYPE, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
	self->type_overrides = _tmp4_;
	_tmp5_ = gee_hash_map_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, (GDestroyNotify) g_free, TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
	self->visibility = _tmp5_;
	_tmp6_ = g_list_store_new (TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY);
	self->visibility_list = _tmp6_;
	self->priv->_unreviewed_follow_requests = 0;
	self->priv->_unread_announcements = 0;
	self->priv->_filtered_notifications_count = 0;
	self->priv->_unread_count = 0;
	self->priv->_last_read_id = 0;
	self->priv->_last_received_id = 0;
	_tmp7_ = g_list_store_new (TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE);
	self->supported_mime_types = _tmp7_;
	self->priv->_tuba_last_fediwrapped_year = 0;
	_tmp8_ = gee_hash_map_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, (GDestroyNotify) g_free, G_TYPE_INT, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
	self->priv->sent_notifications = _tmp8_;
	self->priv->_account_settings = NULL;
}

static void
tuba_instance_account_finalize (GObject * obj)
{
	TubaInstanceAccount * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccount);
	tuba_streamable_destruct_streamable ((TubaStreamable*) self);
	_g_free0 (self->priv->_tuba_iceshrimp_api_key);
	_g_free0 (self->priv->_tuba_streaming_url);
	_g_free0 (self->priv->_backend);
	_g_object_unref0 (self->priv->_instance_info);
	_g_object_unref0 (self->priv->_instance_emojis);
	_g_free0 (self->priv->_instance);
	_g_free0 (self->priv->_client_id);
	_g_free0 (self->priv->_client_secret);
	_g_free0 (self->priv->_access_token);
	_g_object_unref0 (self->priv->_tuba_api_versions);
	_g_object_unref0 (self->known_places);
	_g_object_unref0 (self->list_places);
	_g_object_unref0 (self->tags_places);
	_g_object_unref0 (self->type_overrides);
	_g_free0 (self->priv->_uuid);
	_g_object_unref0 (self->visibility);
	_g_object_unref0 (self->visibility_list);
	_g_object_unref0 (self->supported_mime_types);
	_g_object_unref0 (self->priv->annual_report);
	_g_object_unref0 (self->priv->sent_notifications);
	_g_free0 (self->priv->_t_connection_url);
	_g_object_unref0 (self->priv->_account_settings);
	G_OBJECT_CLASS (tuba_instance_account_parent_class)->finalize (obj);
}

 G_GNUC_NO_INLINE static GType
tuba_instance_account_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (TubaInstanceAccountClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) tuba_instance_account_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (TubaInstanceAccount), 0, (GInstanceInitFunc) tuba_instance_account_instance_init, NULL };
	static const GInterfaceInfo tuba_streamable_info = { (GInterfaceInitFunc) tuba_instance_account_tuba_streamable_interface_init, (GInterfaceFinalizeFunc) NULL, NULL};
	GType tuba_instance_account_type_id;
	tuba_instance_account_type_id = g_type_register_static (TUBA_API_TYPE_ACCOUNT, "TubaInstanceAccount", &g_define_type_info, G_TYPE_FLAG_NONE);
	g_type_add_interface_static (tuba_instance_account_type_id, TUBA_TYPE_STREAMABLE, &tuba_streamable_info);
	TubaInstanceAccount_private_offset = g_type_add_instance_private (tuba_instance_account_type_id, sizeof (TubaInstanceAccountPrivate));
	return tuba_instance_account_type_id;
}

GType
tuba_instance_account_get_type (void)
{
	static GType tuba_instance_account_type_id__once = 0;
	if (g_once_init_enter_pointer (&tuba_instance_account_type_id__once)) {
		GType tuba_instance_account_type_id;
		tuba_instance_account_type_id = tuba_instance_account_get_type_once ();
		g_once_init_leave_pointer (&tuba_instance_account_type_id__once, tuba_instance_account_type_id);
	}
	return tuba_instance_account_type_id__once;
}

static void
_vala_tuba_instance_account_get_property (GObject * object,
                                          guint property_id,
                                          GValue * value,
                                          GParamSpec * pspec)
{
	TubaInstanceAccount * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccount);
	switch (property_id) {
		case TUBA_INSTANCE_ACCOUNT_TUBA_INSTANCE_FEATURES_PROPERTY:
		g_value_set_flags (value, tuba_instance_account_get_tuba_instance_features (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_ICESHRIMP_API_KEY_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_tuba_iceshrimp_api_key (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_STREAMING_URL_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_tuba_streaming_url (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_ADMIN_MODE_PROPERTY:
		g_value_set_boolean (value, tuba_instance_account_get_admin_mode (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_BACKEND_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_backend (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_INSTANCE_INFO_PROPERTY:
		g_value_set_object (value, tuba_instance_account_get_instance_info (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_INSTANCE_EMOJIS_PROPERTY:
		g_value_set_object (value, tuba_instance_account_get_instance_emojis (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_INSTANCE_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_instance (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_CLIENT_ID_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_client_id (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_CLIENT_SECRET_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_client_secret (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_ACCESS_TOKEN_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_access_token (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_NEEDS_UPDATE_PROPERTY:
		g_value_set_boolean (value, tuba_instance_account_get_needs_update (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_PROBABLY_HAS_NOTIFICATION_FILTERS_PROPERTY:
		g_value_set_boolean (value, tuba_instance_account_get_tuba_probably_has_notification_filters (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_REVOKED_PROPERTY:
		g_value_set_boolean (value, tuba_instance_account_get_tuba_revoked (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_CRED_UPDATED_PROPERTY:
		g_value_set_boolean (value, tuba_instance_account_get_tuba_cred_updated (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_VERIFIED_CREDENTIALS_PROPERTY:
		g_value_set_boolean (value, tuba_instance_account_get_tuba_verified_credentials (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_API_VERSIONS_PROPERTY:
		g_value_set_object (value, tuba_instance_account_get_tuba_api_versions (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_HANDLE_SHORT_PROPERTY:
		g_value_take_string (value, tuba_instance_account_get_handle_short (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_HANDLE_PROPERTY:
		g_value_take_string (value, tuba_instance_account_get_handle (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_IS_ACTIVE_PROPERTY:
		g_value_set_boolean (value, tuba_instance_account_get_is_active (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_UUID_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_uuid (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_UNREVIEWED_FOLLOW_REQUESTS_PROPERTY:
		g_value_set_int (value, tuba_instance_account_get_unreviewed_follow_requests (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_UNREAD_ANNOUNCEMENTS_PROPERTY:
		g_value_set_int (value, tuba_instance_account_get_unread_announcements (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_FILTERED_NOTIFICATIONS_COUNT_PROPERTY:
		g_value_set_int (value, tuba_instance_account_get_filtered_notifications_count (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_UNREAD_COUNT_PROPERTY:
		g_value_set_int (value, tuba_instance_account_get_unread_count (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_LAST_READ_ID_PROPERTY:
		g_value_set_int (value, tuba_instance_account_get_last_read_id (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_LAST_RECEIVED_ID_PROPERTY:
		g_value_set_int (value, tuba_instance_account_get_last_received_id (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_LAST_FEDIWRAPPED_YEAR_PROPERTY:
		g_value_set_int (value, tuba_instance_account_get_tuba_last_fediwrapped_year (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_T_CONNECTION_URL_PROPERTY:
		g_value_set_string (value, tuba_streamable_get_t_connection_url ((TubaStreamable*) self));
		break;
		case TUBA_INSTANCE_ACCOUNT_SUBSCRIBED_PROPERTY:
		g_value_set_boolean (value, tuba_streamable_get_subscribed ((TubaStreamable*) self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_tuba_instance_account_set_property (GObject * object,
                                          guint property_id,
                                          const GValue * value,
                                          GParamSpec * pspec)
{
	TubaInstanceAccount * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccount);
	switch (property_id) {
		case TUBA_INSTANCE_ACCOUNT_TUBA_INSTANCE_FEATURES_PROPERTY:
		tuba_instance_account_set_tuba_instance_features (self, g_value_get_flags (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_ICESHRIMP_API_KEY_PROPERTY:
		tuba_instance_account_set_tuba_iceshrimp_api_key (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_STREAMING_URL_PROPERTY:
		tuba_instance_account_set_tuba_streaming_url (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_ADMIN_MODE_PROPERTY:
		tuba_instance_account_set_admin_mode (self, g_value_get_boolean (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_BACKEND_PROPERTY:
		tuba_instance_account_set_backend (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_INSTANCE_INFO_PROPERTY:
		tuba_instance_account_set_instance_info (self, g_value_get_object (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_INSTANCE_EMOJIS_PROPERTY:
		tuba_instance_account_set_instance_emojis (self, g_value_get_object (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_INSTANCE_PROPERTY:
		tuba_instance_account_set_instance (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_CLIENT_ID_PROPERTY:
		tuba_instance_account_set_client_id (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_CLIENT_SECRET_PROPERTY:
		tuba_instance_account_set_client_secret (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_ACCESS_TOKEN_PROPERTY:
		tuba_instance_account_set_access_token (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_NEEDS_UPDATE_PROPERTY:
		tuba_instance_account_set_needs_update (self, g_value_get_boolean (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_PROBABLY_HAS_NOTIFICATION_FILTERS_PROPERTY:
		tuba_instance_account_set_tuba_probably_has_notification_filters (self, g_value_get_boolean (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_REVOKED_PROPERTY:
		tuba_instance_account_set_tuba_revoked (self, g_value_get_boolean (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_CRED_UPDATED_PROPERTY:
		tuba_instance_account_set_tuba_cred_updated (self, g_value_get_boolean (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_VERIFIED_CREDENTIALS_PROPERTY:
		tuba_instance_account_set_tuba_verified_credentials (self, g_value_get_boolean (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_API_VERSIONS_PROPERTY:
		tuba_instance_account_set_tuba_api_versions (self, g_value_get_object (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_UUID_PROPERTY:
		tuba_instance_account_set_uuid (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_UNREVIEWED_FOLLOW_REQUESTS_PROPERTY:
		tuba_instance_account_set_unreviewed_follow_requests (self, g_value_get_int (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_UNREAD_ANNOUNCEMENTS_PROPERTY:
		tuba_instance_account_set_unread_announcements (self, g_value_get_int (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_FILTERED_NOTIFICATIONS_COUNT_PROPERTY:
		tuba_instance_account_set_filtered_notifications_count (self, g_value_get_int (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_UNREAD_COUNT_PROPERTY:
		tuba_instance_account_set_unread_count (self, g_value_get_int (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_LAST_READ_ID_PROPERTY:
		tuba_instance_account_set_last_read_id (self, g_value_get_int (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_LAST_RECEIVED_ID_PROPERTY:
		tuba_instance_account_set_last_received_id (self, g_value_get_int (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_LAST_FEDIWRAPPED_YEAR_PROPERTY:
		tuba_instance_account_set_tuba_last_fediwrapped_year (self, g_value_get_int (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_T_CONNECTION_URL_PROPERTY:
		tuba_streamable_set_t_connection_url ((TubaStreamable*) self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_SUBSCRIBED_PROPERTY:
		tuba_streamable_set_subscribed ((TubaStreamable*) self, g_value_get_boolean (value));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_array_destroy (gpointer array,
                     gssize array_length,
                     GDestroyNotify destroy_func)
{
	if ((array != NULL) && (destroy_func != NULL)) {
		gssize i;
		for (i = 0; i < array_length; i = i + 1) {
			if (((gpointer*) array)[i] != NULL) {
				destroy_func (((gpointer*) array)[i]);
			}
		}
	}
}

static void
_vala_array_free (gpointer array,
                  gssize array_length,
                  GDestroyNotify destroy_func)
{
	_vala_array_destroy (array, array_length, destroy_func);
	g_free (array);
}

