Skip to content

Commit

Permalink
fix - removing added console logs
Browse files Browse the repository at this point in the history
  • Loading branch information
lilla28 committed Sep 4, 2024
1 parent 0fd361d commit 96c9a12
Show file tree
Hide file tree
Showing 5 changed files with 0 additions and 95 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -241,8 +241,6 @@ export class MarketWatchComponent implements OnInit, OnDestroy{

if (data.action === 'BUY') {
const sumQuantity = symbols.reduce((sum, current) => {
console.log(current);
console.log(sum);
if (current.Children && current.Children.length > 0) {
let s: number = current.Children.reduce((t, currentSymbol) => {
if(currentSymbol.AskSize) {
Expand All @@ -256,7 +254,6 @@ export class MarketWatchComponent implements OnInit, OnDestroy{
return sum + 0;
}, 0);

console.log("Sum of the available symbols on the market:", sumQuantity);

if (sumQuantity < data.quantity) {
await this.channel!.broadcast(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1122,62 +1122,6 @@ void FilterAppIntents(Fdc3App app)
return result;
}

private Dictionary<string, AppIntent> GetAppIntentsFromRunningModules(
Func<Fdc3App, Dictionary<string, AppIntent>, IEnumerable<KeyValuePair<string, IntentMetadata>>?> selector,
IAppIdentifier? targetAppIdentifier,
Dictionary<string, AppIntent> appIntents)
{
foreach (var app in _runningModules)
{
if (targetAppIdentifier?.InstanceId != null
&& Guid.TryParse(targetAppIdentifier.InstanceId, out var instanceId)
&& instanceId != app.Key)
{
continue;
}

var intentMetadataCollection = selector(app.Value, appIntents);

if (intentMetadataCollection == null)
{
continue;
}

appIntents = GetAppIntentsFromIntentMetadataCollection(
app.Value,
app.Key.ToString(),
intentMetadataCollection,
appIntents);
}

return appIntents;
}

private async Task<Dictionary<string, AppIntent>> GetAppIntentsFromAppDirectory(
Func<Fdc3App, Dictionary<string, AppIntent>, IEnumerable<KeyValuePair<string, IntentMetadata>>?> selector,
IAppIdentifier? targetAppIdentifier,
Dictionary<string, AppIntent> appIntents)
{
foreach (var app in await _appDirectory.GetApps())
{
if (targetAppIdentifier != null && targetAppIdentifier.AppId != app.AppId)
{
continue;
}

var intentMetadataCollection = selector(app, appIntents);

if (intentMetadataCollection == null)
{
continue;
}

appIntents = GetAppIntentsFromIntentMetadataCollection(app, null, intentMetadataCollection, appIntents);
}

return appIntents;
}

private Dictionary<string, AppIntent> GetAppIntentsFromIntentMetadataCollection(
Fdc3App app,
string? instanceId,
Expand Down Expand Up @@ -1221,38 +1165,6 @@ private Dictionary<string, AppIntent> GetAppIntentsFromIntentMetadataCollection(
return appIntents;
}

private async Task GetAppIntentsFromAppDirectory(
Action<Fdc3App, string?> selector,
IAppIdentifier? targetAppIdentifier)
{
foreach (var app in await _appDirectory.GetApps())
{
if (targetAppIdentifier != null && targetAppIdentifier.AppId != app.AppId)
{
continue;
}

selector(app, null);
}
}

private void GetAppIntentsFromRunningModules(
Action<Fdc3App, string?> selector,
IAppIdentifier? targetAppIdentifier)
{
foreach (var app in _runningModules)
{
if (targetAppIdentifier?.InstanceId != null
&& Guid.TryParse(targetAppIdentifier.InstanceId, out var instanceId)
&& instanceId != app.Key)
{
continue;
}

selector(app.Value, app.Key.ToString());
}
}

private ValueTask<GetInfoResponse> GetAppInfo(IAppIdentifier appIdentifier)
{
if (!Guid.TryParse(appIdentifier.InstanceId!, out var instanceId))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ export class ComposeUIChannel implements Channel {
this.lastContexts.set(context.type, context);
this.lastContext = context;
const topic = ComposeUITopic.broadcast(this.id, this.type);
console.log("Broadcast from channel: ", this.id, this.type, topic, context);
await this.messageRouterClient.publish(topic, JSON.stringify(context));
}

Expand Down Expand Up @@ -80,7 +79,6 @@ export class ComposeUIChannel implements Channel {

const listener = new ComposeUIContextListener(this.messageRouterClient, handler, this.id, this.type, contextType);
await listener.subscribe();
console.log("ContextListener has been added through channel:", contextType);
return listener;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ export class ComposeUIContextListener implements Listener {
//TODO: integration test
const context = <Context>JSON.parse(topicMessage.payload!);
if (!this.contextType || this.contextType == context!.type) {
console.log("ContextListener received context to handle: ", context);
this.handler!(context!);
}
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@ export class ComposeUIIntentListener implements Listener {
request = new Fdc3StoreIntentResultRequest(message.messageId, this.intent, this.instanceId, message.contextMetadata.source.instanceId!, undefined, undefined, undefined, false, ResultError.IntentHandlerRejected);
}

console.log("STORE INTENT RESULT REQUEST:", request);
const result = await this.messageRouterClient.invoke(ComposeUITopic.sendIntentResult(), JSON.stringify(request));
if (!result) {
return;
Expand Down

0 comments on commit 96c9a12

Please sign in to comment.