mirror of
				https://github.com/superseriousbusiness/gotosocial.git
				synced 2025-10-29 04:22:24 -05:00 
			
		
		
		
	[feature] Add domain permission drafts and excludes (#3547)
* [feature] Add domain permission drafts and excludes * fix typescript complaining * lint * make filenames more consistent * test own domain excluded
This commit is contained in:
		
					parent
					
						
							
								c2029df9bc
							
						
					
				
			
			
				commit
				
					
						301543616b
					
				
			
		
					 69 changed files with 5664 additions and 264 deletions
				
			
		|  | @ -3156,6 +3156,37 @@ func SetCacheConversationLastStatusIDsMemRatio(v float64) { | |||
| 	global.SetCacheConversationLastStatusIDsMemRatio(v) | ||||
| } | ||||
| 
 | ||||
| // GetCacheDomainPermissionDraftMemRation safely fetches the Configuration value for state's 'Cache.DomainPermissionDraftMemRation' field | ||||
| func (st *ConfigState) GetCacheDomainPermissionDraftMemRation() (v float64) { | ||||
| 	st.mutex.RLock() | ||||
| 	v = st.config.Cache.DomainPermissionDraftMemRation | ||||
| 	st.mutex.RUnlock() | ||||
| 	return | ||||
| } | ||||
| 
 | ||||
| // SetCacheDomainPermissionDraftMemRation safely sets the Configuration value for state's 'Cache.DomainPermissionDraftMemRation' field | ||||
| func (st *ConfigState) SetCacheDomainPermissionDraftMemRation(v float64) { | ||||
| 	st.mutex.Lock() | ||||
| 	defer st.mutex.Unlock() | ||||
| 	st.config.Cache.DomainPermissionDraftMemRation = v | ||||
| 	st.reloadToViper() | ||||
| } | ||||
| 
 | ||||
| // CacheDomainPermissionDraftMemRationFlag returns the flag name for the 'Cache.DomainPermissionDraftMemRation' field | ||||
| func CacheDomainPermissionDraftMemRationFlag() string { | ||||
| 	return "cache-domain-permission-draft-mem-ratio" | ||||
| } | ||||
| 
 | ||||
| // GetCacheDomainPermissionDraftMemRation safely fetches the value for global configuration 'Cache.DomainPermissionDraftMemRation' field | ||||
| func GetCacheDomainPermissionDraftMemRation() float64 { | ||||
| 	return global.GetCacheDomainPermissionDraftMemRation() | ||||
| } | ||||
| 
 | ||||
| // SetCacheDomainPermissionDraftMemRation safely sets the value for global configuration 'Cache.DomainPermissionDraftMemRation' field | ||||
| func SetCacheDomainPermissionDraftMemRation(v float64) { | ||||
| 	global.SetCacheDomainPermissionDraftMemRation(v) | ||||
| } | ||||
| 
 | ||||
| // GetCacheEmojiMemRatio safely fetches the Configuration value for state's 'Cache.EmojiMemRatio' field | ||||
| func (st *ConfigState) GetCacheEmojiMemRatio() (v float64) { | ||||
| 	st.mutex.RLock() | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue