@@ -15,6 +15,7 @@ import type {
1515 IssueStatus ,
1616 User ,
1717} from '../types' ;
18+ import { logger } from '../helpers/logger' ;
1819
1920const API_BASE = '/data/collaboration' ;
2021
@@ -146,7 +147,7 @@ export async function assignIssue(
146147 userId : string
147148) : Promise < Issue > {
148149 // In production, this would be a POST request
149- console . log ( `Assigning issue ${ issueId } to user ${ userId } ` ) ;
150+ logger . info ( 'collaborationApi' , `Assigning issue ${ issueId } to user ${ userId } ` ) ;
150151 // Return mock updated issue
151152 const issues = await fetchIssues ( ) ;
152153 const issue = issues . find ( ( i ) => i . id === issueId ) ;
@@ -162,7 +163,7 @@ export async function updateIssueStatus(
162163 status : IssueStatus
163164) : Promise < Issue > {
164165 // In production, this would be a PATCH request
165- console . log ( `Updating issue ${ issueId } status to ${ status } ` ) ;
166+ logger . info ( 'collaborationApi' , `Updating issue ${ issueId } status to ${ status } ` ) ;
166167 const issues = await fetchIssues ( ) ;
167168 const issue = issues . find ( ( i ) => i . id === issueId ) ;
168169 if ( ! issue ) throw new Error ( 'Issue not found' ) ;
@@ -178,7 +179,7 @@ export async function addComment(
178179 parentId ?: string
179180) : Promise < Comment > {
180181 // In production, this would be a POST request
181- console . log ( `Adding comment to issue ${ issueId } ` , { text, parentId } ) ;
182+ logger . info ( 'collaborationApi' , `Adding comment to issue ${ issueId } ` , { text, parentId } ) ;
182183 return {
183184 id : `comment-${ Date . now ( ) } ` ,
184185 issueId,
@@ -198,7 +199,7 @@ export async function addComment(
198199 */
199200export async function markActivityAsRead ( activityId : string ) : Promise < void > {
200201 // In production, this would be a PATCH request
201- console . log ( `Marking activity ${ activityId } as read` ) ;
202+ logger . info ( 'collaborationApi' , `Marking activity ${ activityId } as read` ) ;
202203}
203204
204205// Mock data generators
0 commit comments