Added arn to the main repository

This commit is contained in:
2019-06-03 18:32:43 +09:00
parent cf258573a8
commit 29a48d94a5
465 changed files with 15968 additions and 288 deletions
arn
AMV.goAMVAPI.goAMVTitle.goAPIKeys.goActivity.goActivityConsumeAnime.goActivityConsumeAnimeAPI.goActivityCreate.goActivityCreateAPI.goAiringDate.goAnalytics.goAnalyticsAPI.goAniList.goAniListMatch.goAnime.goAnimeAPI.goAnimeCharacter.goAnimeCharacterAPI.goAnimeCharacters.goAnimeCharactersAPI.goAnimeEpisode.goAnimeEpisodes.goAnimeEpisodesAPI.goAnimeFinder.goAnimeImage.goAnimeList.goAnimeListAPI.goAnimeListItem.goAnimeListItemAPI.goAnimeListItemRating.goAnimeList_test.goAnimePopularity.goAnimeRating.goAnimeRelation.goAnimeRelations.goAnimeRelationsAPI.goAnimeSort.goAnimeSort_test.goAnimeTitle.goAnime_test.goAuthorizeHelper.goAvatar.goBot.goCharacter.goCharacterAPI.goCharacterAttribute.goCharacterFinder.goCharacterImage.goCharacterName.goClientErrorReport.goClientErrorReportAPI.goCollectionUtils.goCompany.goCompanyAPI.goCompanyName.goCompanySort.goDataLists.goDatabase.goDatabase_test.goDraftIndex.goDraftIndexAPI.goDraftable.goEditLogEntry.goEditLogEntryAPI.goEmailToUser.goExternalMedia.goExternalMediaAPI.goFacebookToUser.goForumIcons.goGenres.goGoogleToUser.goGroup.goGroupAPI.goGroupImage.goGroupMember.goHSLColor.goHasCreator.goHasDraft.goHasEditing.goHasEditor.goHasID.goHasLikes.goHasLocked.goHasMappings.goHasPosts.goHasText.goIDCollection.goIDList.goIgnoreAnimeDifference.goIgnoreAnimeDifferenceAPI.goInventory.goInventoryAPI.goInventorySlot.goInventory_test.goJapaneseTokenizer.goJoinable.goKitsuAnime.goKitsuMappings.goKitsuMatch.goLICENSELikeable.goLink.goLinkable.goListOfMappedIDs.goLocation.goLockable.goLoggable.goMapping.goMyAnimeListMatch.goName.goNickToUser.goNotification.goNotificationAPI.goNotificationType.goNyaa.goOpenGraph.goPayPal.goPayPalPayment.goPerson.goPersonAPI.goPersonImage.goPersonName.goPost.goPostAPI.goPostParent.goPostable.goProduction.goPublishable.goPurchase.goPurchaseAPI.goPushNotification.goPushSubscription.goPushSubscriptions.goPushSubscriptionsAPI.goQuote.goQuoteAPI.goQuoteText.goREADME.mdREADME.src.mdSession.goSettings.goSettingsAPI.goShopItem.goShopItemAPI.goSoundTrack.goSoundTrackAPI.goSoundTrackLyrics.goSoundTrackTitle.goSoundTrackUtils.goSpoiler.goStatisticsCategory.goStatisticsItem.goThread.goThreadAPI.goTwitterToUser.goUpcomingEpisode.goUser.goUserAPI.goUserAccounts.goUserAvatar.goUserConnectAccounts.goUserCover.goUserEvents.goUserFollows.goUserFollowsAPI.goUserHelper.goUserJoins.goUserNotifications.goUserNotificationsAPI.goUserSubTypes.goUser_test.goUtils.go
autocorrect
autodocs
mailer
osutils
search
stringutils
validate
video
assets
auth
benchmarks
bots/discord
go.modgo.sum
graphql
jobs
main.gomain_test.go
middleware
pages
activity
admin
amv
amvs
anime
animeimport
animelist
animelistitem
apiview
calendar
character
characters
companies
company
compare
editlog
editor
episode
explore
explore.go
explorecolor
explorerelations
halloffame
forum
frontpage
genre
genres
group
groups
index
apiroutes
userroutes
inventory
listimport
listimportanilist
listimportkitsu
listimportmyanimelist
notifications
paypal
popular
post
profile
quote
quotes
recommended
search
settings
shop
soundtrack
soundtracks
statistics
thread
upload
user
users
patches
activity-recreate-from-log
add-character-created-date
add-item
add-shop-items
add-user-notify-email
anime-episodes-sort
anime-status
animelist-remove-duplicates
change-role
character-split-spoilers
character-unescape-name
christmas-notification
clear-anime-ratings
clear-sessions
delete-amv-tags
delete-balance
delete-old-sessions
delete-private-data
delete-pro
delete-unused-characters
email-notification
fix-airing-dates
fix-anime-list-item-status
fix-broken-relations
fix-genres
fix-theme
fix-tvdb-duplicates
fix-user-websites
fix-wrong-ids-in-animelists
import-kitsu-mappings
import-mal-companies
kitsu-anilist
kitsu-download-anime-images
mark-month-as-current
merge-duplicate-characters
notification-delete-old
notification-emails
optimize-all-webm-files
post-sort-date
post-texts
refresh-anime-average-color
refresh-anime-thumbnails
remove-character-borders
reset-animelist-ratings
reset-inventories
reset-notification-settings
show-kitsu-mappings
show-season
show-user-languages
thread-posts
update-amv-info
user-privacy-location
user-references
user-set-social-id
user-show-intros
security.go
utils

20
arn/IDList.go Normal file

@ -0,0 +1,20 @@
package arn
// IDList stores lists of IDs that are retrievable by name.
type IDList []string
// GetIDList ...
func GetIDList(id string) (IDList, error) {
obj, err := DB.Get("IDList", id)
if err != nil {
return nil, err
}
return *obj.(*IDList), nil
}
// Append appends the given ID to the end of the list and returns the new IDList.
func (idList IDList) Append(id string) IDList {
return append(idList, id)
}