This repository was archived by the owner on Sep 10, 2025. It is now read-only.
  
  
  
  
    
    
    
      
    
  
  
    
File tree Expand file tree Collapse file tree 3 files changed +4
-10
lines changed Expand file tree Collapse file tree 3 files changed +4
-10
lines changed Original file line number Diff line number Diff line change 11{
2-   "version" : " 2.0.6 " 
2+   "version" : " 2.0.7 " 
33  "name" : " onenoteapi" 
44  "description" : " JavaScript library to make calling the OneNote API easier." 
55  "main" : " dist/OneNoteApi.js" 
Original file line number Diff line number Diff line change @@ -225,17 +225,11 @@ export class OneNoteApi extends OneNoteApiBase implements IOneNoteApi {
225225	/** 
226226	* GetNotebooksUrl 
227227	*/ 
228- 	private  getNotebooksUrl ( numExpands  =  0 , 
229- 							excludeReadOnlyNotebooks  =  true , 
230- 							orderByCondition  =  null ) : string  { 
228+ 	private  getNotebooksUrl ( numExpands  =  0 ,  excludeReadOnlyNotebooks  =  true ,  orderByCondition  =  null ) : string  { 
231229		// Since this url is most often used to save content to a specific notebook, by default 
232230		// it does not include a notebook where user has Read only permissions. 
233231		let  filter  =  ( excludeReadOnlyNotebooks )  ? "$filter=userRole%20ne%20Microsoft.OneNote.Api.UserRole'Reader'"  : "" ; 
234- 		let  orderByStr  =  "" ; 
235- 		if  ( orderByCondition )  { 
236- 			orderByStr  =  orderByCondition . direction  ? `&$orderby=${ orderByCondition . parameter } ${ orderByCondition . direction }   : `&$orderBy=${ orderByCondition . parameter }  ; 
237- 		} 
238- 
232+ 		let  orderByStr  =  orderByCondition  ? `&$orderby=${ orderByCondition . parameter } ${ orderByCondition . direction }   : "" ; 
239233		return  "/me/notes/notebooks?"  +  filter  +  orderByStr  +  ( numExpands  ? "&"  +  this . getExpands ( numExpands )  : "" ) ; 
240234	} 
241235
Original file line number Diff line number Diff line change @@ -15,5 +15,5 @@ export enum Direction {
1515
1616export  class  OrderBy  { 
1717	public  parameter : Parameter ; 
18- 	public  direction ? : Direction ; 
18+ 	public  direction : Direction ; 
1919} 
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments