All checks were successful
		
		
	
	Build blog docker image / Build-Blog-Image (push) Successful in 49s
				
			将图片压缩为webp格式减少流量使用和磁盘占用 Reviewed-on: #10
		
			
				
	
	
		
			16 lines
		
	
	
		
			453 B
		
	
	
	
		
			C#
		
	
	
	
	
	
			
		
		
	
	
			16 lines
		
	
	
		
			453 B
		
	
	
	
		
			C#
		
	
	
	
	
	
| using System.Collections;
 | |
| using System.Collections.Concurrent;
 | |
| 
 | |
| namespace YaeBlog.Models;
 | |
| 
 | |
| public record BlogContents(ConcurrentBag<BlogContent> Drafts, ConcurrentBag<BlogContent> Posts)
 | |
|     : IEnumerable<BlogContent>
 | |
| {
 | |
|     IEnumerator<BlogContent> IEnumerable<BlogContent>.GetEnumerator()
 | |
|     {
 | |
|         return Posts.Concat(Drafts).GetEnumerator();
 | |
|     }
 | |
| 
 | |
|     public IEnumerator GetEnumerator() => ((IEnumerable<BlogContent>)this).GetEnumerator();
 | |
| }
 |